Commit 36159a57 authored by Eugene M. Kim's avatar Eugene M. Kim

Create install.rdf from a template

This avoids modifying source-controlled files from build.  This also
avoids use of nonstandard -i option (whose backup-less form differs
between the GNU version and the BSD/macOS version).
parent a78ea26f
/install.rdf
version = $(shell cat VERSION)
excludefromxpi = .git/\* .tx/\* \*.xpi \*.sh update\*.txt Makefile VERSION
excludefromxpi = .git/\* .gitignore .tx/\* \*.xpi \*.sh update\*.txt Makefile VERSION install.rdf.template
releasebranch = ec-4.0
# Default target is build package
build:
# Update version number inside install.rdf file from VERSION file
sed -i 's/\(\s*\)<em:version>[^<]*\?<\/em:version>/\1<em:version>$(version)<\/em:version>/' install.rdf
build: install.rdf
# Disable automatic updates of the extension
cat defaults/preferences/update_disable.txt > defaults/preferences/update.js
# Finally, create the xpi file
zip -r exchangecalendar-v"$(version)".xpi -x $(excludefromxpi) -- .
install.rdf: install.rdf.template
sed 's/@VERSION@/$(version)/g' install.rdf.template > install.rdf
# Target to publish a new release:
release: l10n-auto-commit build
git add -- install.rdf
......
......@@ -3,7 +3,7 @@
xmlns:em="http://www.mozilla.org/2004/em-rdf#">
<Description about="urn:mozilla:install-manifest">
<em:id>exchangecalendar@extensions.1st-setup.nl</em:id>
<em:version>4.0.0-beta5</em:version>
<em:version>@VERSION@</em:version>
<em:targetApplication>
<Description>
<!-- Thunderbird -->
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment