[Pkg-mozext-commits] [itsalltext] 420/459: Version wasn't being set in the .xpi
David Prévot
taffit at moszumanska.debian.org
Tue Feb 24 23:26:44 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository itsalltext.
commit 1a7a3283b53c195aacddf71a369d2ffb3f730e85
Author: Christian Höltje <docwhat at gerf.org>
Date: Sat May 18 17:17:23 2013 -0400
Version wasn't being set in the .xpi
Version wasn't being incorporated into the `install.rdf`.
Moved the version file out into a separate file.
---
Rakefile | 16 +++++++---------
version.rb | 1 +
2 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/Rakefile b/Rakefile
index a258b2c..4d36652 100644
--- a/Rakefile
+++ b/Rakefile
@@ -1,7 +1,7 @@
+require_relative 'version'
require 'paint'
require 'set'
-VERSION="1.8.0"
XPI_FILENAME = "itsalltext-#{VERSION}.xpi"
FIREFOX_SOURCE_EXTENSIONS = [
@@ -22,13 +22,10 @@ LANGUAGES = Dir["#{LOCALE_DIR}/*"].select { |p| File.directory?(p) }.map { |p| F
task :default => :build
desc "Build add-on #{VERSION}"
-task :build => [XPI_FILENAME]
-
-# Alias, because I forget.
-task :release => [:build]
+task :build => [:verify, XPI_FILENAME]
desc "Install It's All Text! into firefox"
-task :install => :build do
+task :install => [:verify, :build] do
sh 'open', '-a', 'Firefox', XPI_FILENAME
end
@@ -44,7 +41,7 @@ task :verify do
errors = errors.flatten.select { |e| !e.nil? }
if errors.size > 0
errors.each { |error| puts "ERROR: #{error}" }
- raise "There were problems with the translations."
+ fail "There were problems with the translations."
end
end
@@ -111,9 +108,10 @@ def diff_locale language
errors.flatten.select { |e| !e.nil? }
end
-file "final" => FIREFOX_SOURCES do |t|
+file "final" => FIREFOX_SOURCES + ['version.rb'] do |t|
rm_rf 'final'
t.prerequisites.each do |src|
+ next unless src =~ %r{\Asrc}
dst = src.sub(%r{\Asrc/}, 'final/')
dst_parent = File.dirname(dst)
mkdir_p dst_parent unless File.directory?(dst_parent)
@@ -128,7 +126,7 @@ file "final" => FIREFOX_SOURCES do |t|
end
end
-file XPI_FILENAME => [:verify, "final"] do |t|
+file XPI_FILENAME => "final" do |t|
rm_f t.name
xpi_path = File.expand_path(t.name)
Dir.chdir "final" do
diff --git a/version.rb b/version.rb
new file mode 100644
index 0000000..b25d90a
--- /dev/null
+++ b/version.rb
@@ -0,0 +1 @@
+VERSION="1.8.0"
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/itsalltext.git
More information about the Pkg-mozext-commits
mailing list