Merge lp:~dobey/indicator-power/fix-i18n into lp:indicator-power

Proposed by dobey
Status: Superseded
Proposed branch: lp:~dobey/indicator-power/fix-i18n
Merge into: lp:indicator-power
Diff against target: 522 lines (+258/-165)
10 files modified
.bzrignore (+4/-0)
CMakeLists.txt (+9/-20)
cmake/GCov.cmake (+0/-51)
cmake/Translations.cmake (+0/-37)
debian/control (+7/-5)
po/CMakeLists.txt (+12/-3)
po/POTFILES.in (+0/-4)
po/indicator-power.pot (+217/-0)
tests/CMakeLists.txt (+9/-7)
tests/Makefile.am.strings (+0/-38)
To merge this branch: bzr merge lp:~dobey/indicator-power/fix-i18n
Reviewer Review Type Date Requested Status
Indicator Applet Developers Pending
Review via email: mp+316623@code.launchpad.net

Commit message

Use intltool support from cmake-extras.

To post a comment you must log in.

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== added file '.bzrignore'
--- .bzrignore 1970-01-01 00:00:00 +0000
+++ .bzrignore 2017-02-07 20:21:19 +0000
@@ -0,0 +1,4 @@
1build/
2po/Makefile.in.in
3po/POTFILES.in
4
05
=== modified file 'CMakeLists.txt'
--- CMakeLists.txt 2016-05-16 18:09:57 +0000
+++ CMakeLists.txt 2017-02-07 20:21:19 +0000
@@ -13,9 +13,6 @@
13 -DLOW_BATTERY_SOUND="Low battery.ogg"13 -DLOW_BATTERY_SOUND="Low battery.ogg"
14)14)
1515
16option (enable_tests "Build the package's automatic tests." ON)
17option (enable_lcov "Generate lcov code coverage reports." ON)
18
19set(SERVICE_LIB "indicatorpowerservice")16set(SERVICE_LIB "indicatorpowerservice")
20set(SERVICE_EXEC "indicator-power-service")17set(SERVICE_EXEC "indicator-power-service")
21add_definitions(-DSERVICE_EXEC="${SERVICE_EXEC}")18add_definitions(-DSERVICE_EXEC="${SERVICE_EXEC}")
@@ -59,9 +56,6 @@
59 COMMAND bzr export --root=${ARCHIVE_NAME} ${CMAKE_BINARY_DIR}/${ARCHIVE_NAME}.tar.gz56 COMMAND bzr export --root=${ARCHIVE_NAME} ${CMAKE_BINARY_DIR}/${ARCHIVE_NAME}.tar.gz
60 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})57 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
6158
62add_custom_target (clean-coverage
63 COMMAND find ${CMAKE_BINARY_DIR} -name '*.gcda' | xargs rm -f)
64
65add_custom_target (cppcheck COMMAND cppcheck --enable=all -q --error-exitcode=2 --inline-suppr59add_custom_target (cppcheck COMMAND cppcheck --enable=all -q --error-exitcode=2 --inline-suppr
66 ${CMAKE_SOURCE_DIR}/src60 ${CMAKE_SOURCE_DIR}/src
67 ${CMAKE_SOURCE_DIR}/tests)61 ${CMAKE_SOURCE_DIR}/tests)
@@ -83,22 +77,17 @@
83include_directories (${CMAKE_CURRENT_SOURCE_DIR}/include)77include_directories (${CMAKE_CURRENT_SOURCE_DIR}/include)
84include_directories (${CMAKE_CURRENT_BINARY_DIR}/include)78include_directories (${CMAKE_CURRENT_BINARY_DIR}/include)
8579
86# testing & coverage
87if (${enable_tests})
88 set (GTEST_SOURCE_DIR /usr/src/gtest/src)
89 set (GTEST_INCLUDE_DIR ${GTEST_SOURCE_DIR}/..)
90 set (GTEST_LIBS -lpthread)
91 enable_testing ()
92 if (${enable_lcov})
93 include(GCov)
94 endif ()
95endif ()
96
97# actually build things80# actually build things
98add_subdirectory(src)81add_subdirectory(src)
99add_subdirectory(data)82add_subdirectory(data)
100add_subdirectory(po)83add_subdirectory(po)
101if (${enable_tests})
102 add_subdirectory(tests)
103endif ()
10484
85# testing & coverage
86enable_testing ()
87add_subdirectory(tests)
88find_package(CoverageReport)
89ENABLE_COVERAGE_REPORT(
90 TARGETS ${SERVICE_LIB} ${SERVICE_EXEC}
91 TESTS ${COVERAGE_TEST_TARGETS}
92 FILTER /usr/include ${CMAKE_BINARY_DIR}/*
93)
10594
=== removed file 'cmake/GCov.cmake'
--- cmake/GCov.cmake 2014-07-14 04:43:41 +0000
+++ cmake/GCov.cmake 1970-01-01 00:00:00 +0000
@@ -1,51 +0,0 @@
1if (CMAKE_BUILD_TYPE MATCHES coverage)
2 set(GCOV_FLAGS "${GCOV_FLAGS} --coverage")
3 set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${GCOV_FLAGS}")
4 set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${GCOV_FLAGS}")
5 set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${GCOV_FLAGS}")
6 set(GCOV_LIBS ${GCOV_LIBS} gcov)
7
8 find_program(GCOVR_EXECUTABLE gcovr HINTS ${GCOVR_ROOT} "${GCOVR_ROOT}/bin")
9 if (NOT GCOVR_EXECUTABLE)
10 message(STATUS "Gcovr binary was not found, can not generate XML coverage info.")
11 else ()
12 message(STATUS "Gcovr found, can generate XML coverage info.")
13 add_custom_target (coverage-xml
14 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
15 COMMAND "${GCOVR_EXECUTABLE}" --exclude="test.*" -x -r "${CMAKE_SOURCE_DIR}"
16 --object-directory=${CMAKE_BINARY_DIR} -o coverage.xml)
17 endif()
18
19 find_program(LCOV_EXECUTABLE lcov HINTS ${LCOV_ROOT} "${GCOVR_ROOT}/bin")
20 find_program(GENHTML_EXECUTABLE genhtml HINTS ${GENHTML_ROOT})
21 if (NOT LCOV_EXECUTABLE)
22 message(STATUS "Lcov binary was not found, can not generate HTML coverage info.")
23 else ()
24 if(NOT GENHTML_EXECUTABLE)
25 message(STATUS "Genthml binary not found, can not generate HTML coverage info.")
26 else()
27 message(STATUS "Lcov and genhtml found, can generate HTML coverage info.")
28 add_custom_target (coverage-html
29 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
30 COMMAND "${CMAKE_CTEST_COMMAND}" --force-new-ctest-process --verbose
31 COMMAND "${LCOV_EXECUTABLE}" --directory ${CMAKE_BINARY_DIR} --capture | ${CMAKE_SOURCE_DIR}/trim-lcov.py > dconf-lcov.info
32 COMMAND "${LCOV_EXECUTABLE}" -r dconf-lcov.info /usr/include/\\* -o nosys-lcov.info
33 COMMAND LANG=C "${GENHTML_EXECUTABLE}" --prefix ${CMAKE_BINARY_DIR} --output-directory lcov-html --legend --show-details nosys-lcov.info
34 COMMAND ${CMAKE_COMMAND} -E echo ""
35 COMMAND ${CMAKE_COMMAND} -E echo "file://${CMAKE_BINARY_DIR}/lcov-html/index.html"
36 COMMAND ${CMAKE_COMMAND} -E echo "")
37 #COMMAND "${LCOV_EXECUTABLE}" --directory ${CMAKE_BINARY_DIR} --capture --output-file coverage.info --no-checksum
38 #COMMAND "${GENHTML_EXECUTABLE}" --prefix ${CMAKE_BINARY_DIR} --output-directory coveragereport --title "Code Coverage" --legend --show-details coverage.info
39 #COMMAND ${CMAKE_COMMAND} -E echo "\\#define foo \\\"bar\\\""
40 #)
41 endif()
42 endif()
43endif()
44
45
46 #$(MAKE) $(AM_MAKEFLAGS) check
47 #lcov --directory $(top_builddir) --capture --test-name dconf | $(top_srcdir)/trim-lcov.py > dconf-lcov.info
48 #LANG=C genhtml --prefix $(top_builddir) --output-directory lcov-html --legend --show-details dconf-lcov.info
49 #@echo
50 #@echo " file://$(abs_top_builddir)/lcov-html/index.html"
51 #@echo
520
=== removed file 'cmake/Translations.cmake'
--- cmake/Translations.cmake 2014-08-09 23:19:02 +0000
+++ cmake/Translations.cmake 1970-01-01 00:00:00 +0000
@@ -1,37 +0,0 @@
1# Translations.cmake, CMake macros written for Marlin, feel free to re-use them
2
3macro(add_translations_directory NLS_PACKAGE)
4 add_custom_target (i18n ALL)
5 find_program (MSGFMT_EXECUTABLE msgfmt)
6 file (GLOB PO_FILES ${CMAKE_CURRENT_SOURCE_DIR}/*.po)
7 foreach (PO_INPUT ${PO_FILES})
8 get_filename_component (PO_INPUT_BASE ${PO_INPUT} NAME_WE)
9 set (MO_OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${PO_INPUT_BASE}.mo)
10 add_custom_command (TARGET i18n COMMAND ${MSGFMT_EXECUTABLE} -o ${MO_OUTPUT} ${PO_INPUT})
11
12 install (FILES ${MO_OUTPUT} DESTINATION
13 ${CMAKE_INSTALL_LOCALEDIR}/${PO_INPUT_BASE}/LC_MESSAGES
14 RENAME ${NLS_PACKAGE}.mo)
15 endforeach (PO_INPUT ${PO_FILES})
16endmacro(add_translations_directory)
17
18
19macro(add_translations_catalog NLS_PACKAGE)
20 add_custom_target (pot COMMENT “Building translation catalog.”)
21 find_program (XGETTEXT_EXECUTABLE xgettext)
22
23 # init this list, which will hold all the sources across all dirs
24 set(SOURCES "")
25
26 # add each directory's sources to the overall sources list
27 foreach(FILES_INPUT ${ARGN})
28 set (DIR ${CMAKE_CURRENT_SOURCE_DIR}/${FILES_INPUT})
29 file (GLOB_RECURSE DIR_SOURCES ${DIR}/*.c ${DIR}/*.cc ${DIR}/*.cpp ${DIR}/*.cxx ${DIR}/*.vala)
30 set (SOURCES ${SOURCES} ${DIR_SOURCES})
31 endforeach()
32
33 add_custom_command (TARGET pot COMMAND
34 ${XGETTEXT_EXECUTABLE} -d ${NLS_PACKAGE} -o ${CMAKE_CURRENT_SOURCE_DIR}/${NLS_PACKAGE}.pot
35 ${SOURCES} --keyword="_" --keyword="N_" --from-code=UTF-8
36 )
37endmacro()
380
=== modified file 'debian/control'
--- debian/control 2016-07-19 10:25:12 +0000
+++ debian/control 2017-02-07 20:21:19 +0000
@@ -3,6 +3,12 @@
3Priority: optional3Priority: optional
4Maintainer: Ubuntu Core Developers <ubuntu-devel-discuss@lists.ubuntu.com>4Maintainer: Ubuntu Core Developers <ubuntu-devel-discuss@lists.ubuntu.com>
5Build-Depends: cmake,5Build-Depends: cmake,
6 cmake-extras (>= 0.10),
7 debhelper (>= 9),
8 dh-translations,
9 gcovr,
10 intltool,
11 lcov,
6 libnotify-dev (>= 0.7.6),12 libnotify-dev (>= 0.7.6),
7 libglib2.0-dev (>= 2.36),13 libglib2.0-dev (>= 2.36),
8 libgudev-1.0-dev,14 libgudev-1.0-dev,
@@ -10,12 +16,8 @@
10 python:any,16 python:any,
11# for com.ubuntu.touch.AccountsService.Sound.xml17# for com.ubuntu.touch.AccountsService.Sound.xml
12 accountsservice-ubuntu-schemas,18 accountsservice-ubuntu-schemas,
13# for packaging
14 debhelper (>= 9),
15 dh-translations,
16 intltool,
17# for tests19# for tests
18 libgtest-dev,20 googletest | google-mock,
19 python3-dbusmock,21 python3-dbusmock,
20 dbus-test-runner,22 dbus-test-runner,
21 libdbustest1-dev,23 libdbustest1-dev,
2224
=== modified file 'po/CMakeLists.txt'
--- po/CMakeLists.txt 2014-07-16 23:29:24 +0000
+++ po/CMakeLists.txt 2017-02-07 20:21:19 +0000
@@ -1,3 +1,12 @@
1include (Translations)1find_package(Intltool REQUIRED)
2add_translations_directory ("${GETTEXT_PACKAGE}")2
3add_translations_catalog ("${GETTEXT_PACKAGE}" ../src/)3intltool_update_potfile(
4 KEYWORDS "_" "_:1,2" "N_" "N_:1,2"
5 GETTEXT_PACKAGE ${GETTEXT_PACKAGE}
6 COPYRIGHT_HOLDER "Canonical Ltd."
7)
8
9intltool_install_translations(
10 ALL
11 GETTEXT_PACKAGE ${GETTEXT_PACKAGE}
12)
413
=== removed file 'po/POTFILES.in'
--- po/POTFILES.in 2014-10-14 09:00:13 +0000
+++ po/POTFILES.in 1970-01-01 00:00:00 +0000
@@ -1,4 +0,0 @@
1data/com.canonical.indicator.power.gschema.xml.in
2src/device.c
3src/notifier.c
4src/service.c
50
=== added file 'po/indicator-power.pot'
--- po/indicator-power.pot 1970-01-01 00:00:00 +0000
+++ po/indicator-power.pot 2017-02-07 20:21:19 +0000
@@ -0,0 +1,217 @@
1# SOME DESCRIPTIVE TITLE.
2# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3# This file is distributed under the same license as the PACKAGE package.
4# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5#
6#, fuzzy
7msgid ""
8msgstr ""
9"Project-Id-Version: PACKAGE VERSION\n"
10"Report-Msgid-Bugs-To: \n"
11"POT-Creation-Date: 2017-02-07 15:18-0500\n"
12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14"Language-Team: LANGUAGE <LL@li.org>\n"
15"Language: \n"
16"MIME-Version: 1.0\n"
17"Content-Type: text/plain; charset=UTF-8\n"
18"Content-Transfer-Encoding: 8bit\n"
19"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
20
21#. TRANSLATORS: system power cord
22#: ../src/device.c:524
23msgid "AC Adapter"
24msgstr ""
25
26#. TRANSLATORS: laptop primary battery
27#: ../src/device.c:528 ../src/service.c:442
28msgid "Battery"
29msgstr ""
30
31#. TRANSLATORS: battery-backed AC power source
32#: ../src/device.c:532
33msgid "UPS"
34msgstr ""
35
36#. TRANSLATORS: a monitor is a device to measure voltage and current
37#: ../src/device.c:536
38msgid "Monitor"
39msgstr ""
40
41#. TRANSLATORS: wireless mice with internal batteries
42#: ../src/device.c:540
43msgid "Mouse"
44msgstr ""
45
46#. TRANSLATORS: wireless keyboard with internal battery
47#: ../src/device.c:544
48msgid "Keyboard"
49msgstr ""
50
51#. TRANSLATORS: portable device
52#: ../src/device.c:548
53msgid "PDA"
54msgstr ""
55
56#. TRANSLATORS: cell phone (mobile...)
57#: ../src/device.c:552
58msgid "Cell phone"
59msgstr ""
60
61#. TRANSLATORS: media player, mp3 etc
62#: ../src/device.c:556
63msgid "Media player"
64msgstr ""
65
66#. TRANSLATORS: tablet device
67#: ../src/device.c:560
68msgid "Tablet"
69msgstr ""
70
71#. TRANSLATORS: tablet device
72#: ../src/device.c:564
73msgid "Computer"
74msgstr ""
75
76#. TRANSLATORS: unknown device
77#: ../src/device.c:568
78msgid "Unknown"
79msgstr ""
80
81#: ../src/device.c:608
82#, c-format
83msgid "estimating…"
84msgstr ""
85
86#: ../src/device.c:612
87#, c-format
88msgid "unknown"
89msgstr ""
90
91#. TRANSLATORS: H:MM (hours, minutes) to charge the battery. Example: "1:30 to charge"
92#: ../src/device.c:641
93#, c-format
94msgid "%0d:%02d to charge"
95msgstr ""
96
97#. TRANSLATORS: H:MM (hours, minutes) to discharge the battery. Example: "1:30 left"
98#: ../src/device.c:646
99#, c-format
100msgid "%0d:%02d left"
101msgstr ""
102
103#. TRANSLATORS: "X (hour,hours) Y (minute,minutes) to charge" the battery.
104#. Example: "1 hour 10 minutes to charge"
105#: ../src/device.c:681
106#, c-format
107msgid "%d %s %d %s to charge"
108msgstr ""
109
110#: ../src/device.c:682 ../src/device.c:700
111msgid "hour"
112msgid_plural "hours"
113msgstr[0] ""
114msgstr[1] ""
115
116#: ../src/device.c:683 ../src/device.c:690 ../src/device.c:701
117#: ../src/device.c:708
118msgid "minute"
119msgid_plural "minutes"
120msgstr[0] ""
121msgstr[1] ""
122
123#. TRANSLATORS: "Y (minute,minutes) to charge" the battery.
124#. Example: "59 minutes to charge"
125#: ../src/device.c:689
126#, c-format
127msgid "%d %s to charge"
128msgstr ""
129
130#. TRANSLATORS: "X (hour,hours) Y (minute,minutes) left" until the battery's empty.
131#. Example: "1 hour 10 minutes left"
132#: ../src/device.c:699
133#, c-format
134msgid "%d %s %d %s left"
135msgstr ""
136
137#. TRANSLATORS: "Y (minute,minutes) left" until the battery's empty.
138#. Example: "59 minutes left"
139#: ../src/device.c:707
140#, c-format
141msgid "%d %s left"
142msgstr ""
143
144#. TRANSLATORS: example: "battery (charged)"
145#: ../src/device.c:764
146#, c-format
147msgid "%s (charged)"
148msgstr ""
149
150#. TRANSLATORS: example: "battery (time remaining)"
151#: ../src/device.c:781
152#, c-format
153msgid "%s (%s)"
154msgstr ""
155
156#. TRANSLATORS: after the icon, a time-remaining string + battery %. Example: "(0:59, 33%)"
157#: ../src/device.c:853
158#, c-format
159msgid "(%s, %.0lf%%)"
160msgstr ""
161
162#. TRANSLATORS: after the icon, a time-remaining string Example: "(0:59)"
163#: ../src/device.c:858
164#, c-format
165msgid "(%s)"
166msgstr ""
167
168#. TRANSLATORS: after the icon, a battery %. Example: "(33%)"
169#: ../src/device.c:863
170#, c-format
171msgid "(%.0lf%%)"
172msgstr ""
173
174#: ../src/notifier.c:286
175msgid "Battery Low"
176msgstr ""
177
178#: ../src/notifier.c:287
179msgid "Battery Critical"
180msgstr ""
181
182#: ../src/notifier.c:289
183#, c-format
184msgid "%.0f%% charge remaining"
185msgstr ""
186
187#: ../src/notifier.c:321
188msgid "OK"
189msgstr ""
190
191#: ../src/notifier.c:322
192msgid "Battery settings"
193msgstr ""
194
195#: ../src/service.c:567
196msgid "Charge level"
197msgstr ""
198
199#: ../src/service.c:635
200msgid "Show Time in Menu Bar"
201msgstr ""
202
203#: ../src/service.c:639
204msgid "Show Percentage in Menu Bar"
205msgstr ""
206
207#: ../src/service.c:643
208msgid "Power Settings…"
209msgstr ""
210
211#: ../src/service.c:669
212msgid "Adjust brightness automatically"
213msgstr ""
214
215#: ../src/service.c:675
216msgid "Battery settings…"
217msgstr ""
0218
=== modified file 'tests/CMakeLists.txt'
--- tests/CMakeLists.txt 2016-05-16 17:59:03 +0000
+++ tests/CMakeLists.txt 2017-02-07 20:21:19 +0000
@@ -1,9 +1,5 @@
1# build libgtest1find_package(GMock)
2add_library (gtest STATIC 2include_directories(${GMOCK_INCLUDE_DIRS})
3 ${GTEST_SOURCE_DIR}/gtest-all.cc
4 ${GTEST_SOURCE_DIR}/gtest_main.cc)
5set_target_properties (gtest PROPERTIES INCLUDE_DIRECTORIES ${INCLUDE_DIRECTORIES} ${GTEST_INCLUDE_DIR})
6set_target_properties (gtest PROPERTIES COMPILE_FLAGS ${COMPILE_FLAGS} -w)
73
8# dbustest4# dbustest
9pkg_check_modules(DBUSTEST REQUIRED5pkg_check_modules(DBUSTEST REQUIRED
@@ -47,11 +43,17 @@
4743
48function(add_test_by_name name)44function(add_test_by_name name)
49 set (TEST_NAME ${name})45 set (TEST_NAME ${name})
46 set (COVERAGE_TEST_TARGETS ${COVERAGE_TEST_TARGETS} ${TEST_NAME} PARENT_SCOPE)
50 add_executable (${TEST_NAME} ${TEST_NAME}.cc gschemas.compiled)47 add_executable (${TEST_NAME} ${TEST_NAME}.cc gschemas.compiled)
51 add_test (${TEST_NAME} ${TEST_NAME})48 add_test (${TEST_NAME} ${TEST_NAME})
52 add_dependencies (${TEST_NAME} ${SERVICE_LIB})49 add_dependencies (${TEST_NAME} ${SERVICE_LIB})
53 target_link_libraries (${TEST_NAME} ${SERVICE_LIB} gtest ${DBUSTEST_LIBRARIES} ${SERVICE_DEPS_LIBRARIES} ${GTEST_LIBS})50 target_link_libraries (${TEST_NAME} ${SERVICE_LIB} ${DBUSTEST_LIBRARIES} ${SERVICE_DEPS_LIBRARIES} ${GMOCK_LIBRARIES})
54endfunction()51endfunction()
55add_test_by_name(test-notify)52add_test_by_name(test-notify)
56add_test(NAME dear-reader-the-next-test-takes-80-seconds COMMAND true)53add_test(NAME dear-reader-the-next-test-takes-80-seconds COMMAND true)
57add_test_by_name(test-device)54add_test_by_name(test-device)
55
56set(COVERAGE_TEST_TARGETS
57 ${COVERAGE_TEST_TARGETS}
58 PARENT_SCOPE
59)
5860
=== removed file 'tests/Makefile.am.strings'
--- tests/Makefile.am.strings 2012-05-24 14:49:30 +0000
+++ tests/Makefile.am.strings 1970-01-01 00:00:00 +0000
@@ -1,38 +0,0 @@
1TESTS += \
2 test-ellipsis \
3 test-space-ellipsis \
4 test-ascii-quotes
5
6#####
7# Tests for there being proper ellipsis instead of three periods in a row
8#####
9test-ellipsis: $(top_srcdir)/po
10 @echo "#!/bin/bash" > $@
11 @echo "(cd $(top_srcdir)/po && make $(GETTEXT_PACKAGE).pot)" >> $@
12 @echo "grep -c -e \"^msgid.*\.\.\.\\\"\" $(top_srcdir)/po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"Ellipsis found in user visible strings\" >&2 && exit 1" >> $@
13 @echo "exit 0" >> $@
14 @chmod +x $@
15
16#####
17# Tests for there being a space before an ellipsis
18#####
19test-space-ellipsis: $(top_srcdir)/po
20 @echo "#!/bin/bash" > $@
21 @echo "(cd $(top_srcdir)/po && make $(GETTEXT_PACKAGE).pot)" >> $@
22 @echo "grep -c -e \"^msgid.* …\\\"\" $(top_srcdir)/po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"Space before ellipsis found in user visible strings\" >&2 && exit 1" >> $@
23 @echo "exit 0" >> $@
24 @chmod +x $@
25
26#####
27# Tests for ASCII quote types
28#####
29test-ascii-quotes: $(top_srcdir)/po
30 @echo "#!/bin/bash" > $@
31 @echo "(cd $(top_srcdir)/po && make $(GETTEXT_PACKAGE).pot)" >> $@
32 @echo "grep -c -e \"^msgid \\\".*'.*\\\"\" $(top_srcdir)/po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"ASCII apostrophy found in user visible strings\" >&2 && exit 1" >> $@
33 @echo "grep -c -e \"^msgid \\\".*\\\".*\\\"\" $(top_srcdir)/po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"ASCII quote found in user visible strings\" >&2 && exit 1" >> $@
34 @echo "grep -c -e \"^msgid \\\".*\\\`.*\\\"\" $(top_srcdir)/po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"ASCII backtick found in user visible strings\" >&2 && exit 1" >> $@
35 @echo "exit 0" >> $@
36 @chmod +x $@
37
38CLEANFILES += $(TESTS)

Subscribers

People subscribed via source and target branches