diff options
author | ArthurHoaro <arthur@hoa.ro> | 2017-05-20 15:53:35 +0200 |
---|---|---|
committer | ArthurHoaro <arthur@hoa.ro> | 2017-10-22 12:56:55 +0200 |
commit | d6379763290230242caac5fe1e7c589a29fa6bf0 (patch) | |
tree | 71233479639b7fa0cc5136fa1e488a9ce314ada8 /Makefile | |
parent | 40ec173e68d47c821cb09875a44aab81d33cd89d (diff) | |
download | Shaarli-d6379763290230242caac5fe1e7c589a29fa6bf0.tar.gz Shaarli-d6379763290230242caac5fe1e7c589a29fa6bf0.tar.zst Shaarli-d6379763290230242caac5fe1e7c589a29fa6bf0.zip |
Use makefile target to generate MO file and remove it from git
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 15 |
1 files changed, 10 insertions, 5 deletions
@@ -130,7 +130,7 @@ check_permissions: | |||
130 | # See phpunit.xml for configuration | 130 | # See phpunit.xml for configuration |
131 | # https://phpunit.de/manual/current/en/appendixes.configuration.html | 131 | # https://phpunit.de/manual/current/en/appendixes.configuration.html |
132 | ## | 132 | ## |
133 | test: | 133 | test: translate |
134 | @echo "-------" | 134 | @echo "-------" |
135 | @echo "PHPUNIT" | 135 | @echo "PHPUNIT" |
136 | @echo "-------" | 136 | @echo "-------" |
@@ -168,15 +168,15 @@ composer_dependencies: clean | |||
168 | composer install --no-dev --prefer-dist | 168 | composer install --no-dev --prefer-dist |
169 | find vendor/ -name ".git" -type d -exec rm -rf {} + | 169 | find vendor/ -name ".git" -type d -exec rm -rf {} + |
170 | 170 | ||
171 | ### generate a release tarball and include 3rd-party dependencies | 171 | ### generate a release tarball and include 3rd-party dependencies and translations |
172 | release_tar: composer_dependencies htmldoc | 172 | release_tar: composer_dependencies htmldoc translate |
173 | git archive --prefix=$(ARCHIVE_PREFIX) -o $(ARCHIVE_VERSION).tar HEAD | 173 | git archive --prefix=$(ARCHIVE_PREFIX) -o $(ARCHIVE_VERSION).tar HEAD |
174 | tar rvf $(ARCHIVE_VERSION).tar --transform "s|^vendor|$(ARCHIVE_PREFIX)vendor|" vendor/ | 174 | tar rvf $(ARCHIVE_VERSION).tar --transform "s|^vendor|$(ARCHIVE_PREFIX)vendor|" vendor/ |
175 | tar rvf $(ARCHIVE_VERSION).tar --transform "s|^doc/html|$(ARCHIVE_PREFIX)doc/html|" doc/html/ | 175 | tar rvf $(ARCHIVE_VERSION).tar --transform "s|^doc/html|$(ARCHIVE_PREFIX)doc/html|" doc/html/ |
176 | gzip $(ARCHIVE_VERSION).tar | 176 | gzip $(ARCHIVE_VERSION).tar |
177 | 177 | ||
178 | ### generate a release zip and include 3rd-party dependencies | 178 | ### generate a release zip and include 3rd-party dependencies and translations |
179 | release_zip: composer_dependencies htmldoc | 179 | release_zip: composer_dependencies htmldoc translate |
180 | git archive --prefix=$(ARCHIVE_PREFIX) -o $(ARCHIVE_VERSION).zip -9 HEAD | 180 | git archive --prefix=$(ARCHIVE_PREFIX) -o $(ARCHIVE_VERSION).zip -9 HEAD |
181 | mkdir -p $(ARCHIVE_PREFIX)/{doc,vendor} | 181 | mkdir -p $(ARCHIVE_PREFIX)/{doc,vendor} |
182 | rsync -a doc/html/ $(ARCHIVE_PREFIX)doc/html/ | 182 | rsync -a doc/html/ $(ARCHIVE_PREFIX)doc/html/ |
@@ -213,3 +213,8 @@ htmldoc: | |||
213 | mkdocs build' | 213 | mkdocs build' |
214 | find doc/html/ -type f -exec chmod a-x '{}' \; | 214 | find doc/html/ -type f -exec chmod a-x '{}' \; |
215 | rm -r venv | 215 | rm -r venv |
216 | |||
217 | |||
218 | ### Generate Shaarli's translation compiled file (.mo) | ||
219 | translate: | ||
220 | @find inc/languages/ -name shaarli.po -execdir msgfmt shaarli.po -o shaarli.mo \; \ No newline at end of file | ||