[vcmi] 04/05: add debian/patches/20150204-let-vcmibuilder-be-case-insensitive

Johannes Schauer josch-guest at moszumanska.debian.org
Wed Feb 4 15:59:41 UTC 2015


This is an automated email from the git hooks/post-receive script.

josch-guest pushed a commit to branch master
in repository vcmi.

commit 623ce8366076672971c814461b9d1858b783b18f
Author: josch <j.schauer at email.de>
Date:   Wed Feb 4 15:42:11 2015 +0100

    add debian/patches/20150204-let-vcmibuilder-be-case-insensitive
---
 debian/changelog                                   |  2 ++
 .../20150204-let-vcmibuilder-be-case-insensitive   | 32 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 35 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 4086669..1aa813b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,8 @@ vcmi (0.97+dfsg-4) UNRELEASED; urgency=medium
   * change my email in Uploaders field to josch at debian.org
   * d/watch: use repacksuffix and use dversionmangle instead of uversionmangle
   * d/rules: add get-orig-source target
+  * add debian/patches/20150204-let-vcmibuilder-be-case-insensitive
+    (Closes: #771300)
 
  -- Johannes Schauer <josch at debian.org>  Wed, 04 Feb 2015 15:31:31 +0100
 
diff --git a/debian/patches/20150204-let-vcmibuilder-be-case-insensitive b/debian/patches/20150204-let-vcmibuilder-be-case-insensitive
new file mode 100644
index 0000000..6e947e9
--- /dev/null
+++ b/debian/patches/20150204-let-vcmibuilder-be-case-insensitive
@@ -0,0 +1,32 @@
+Author: josch <j.schauer at email.de>
+Subject: let data, maps and mp3 directory be truly case insensitive
+Forwarded: https://github.com/vcmi/vcmi/pull/63
+
+diff --git a/vcmibuilder b/vcmibuilder
+index 59ac71e..36de603 100755
+--- a/vcmibuilder
++++ b/vcmibuilder
+@@ -209,17 +209,13 @@ fi
+ 
+ if [[ -n "$data_dir" ]]
+ then
+-	cp -r "$data_dir"/Data "$dest_dir" 
+-	cp -r "$data_dir"/Maps "$dest_dir"
+-
+ 	# this folder is named differently from time to time
+-	# vcmi can handle any case but script can't
+-	if [ -d "$data_dir"/MP3 ] 
+-	then
+-		cp -r "$data_dir"/MP3 "$dest_dir"
+-	else
+-		cp -r "$data_dir"/Mp3 "$dest_dir"
+-	fi
++	# bash also has `shopt -s nocaseglob` but we don't want this to
++	# accidentally influence other parts of this script
++	# since the directory names are short, we use this pattern matching
++	cp -r "$data_dir"/[Dd][Aa][Tt][Aa] "$dest_dir" 
++	cp -r "$data_dir"/[Mm][Aa][Pp][Ss] "$dest_dir"
++	cp -r "$data_dir"/[Mm][Pp]3 "$dest_dir"
+ fi
+ 
+ if [[ -n "$download" ]]
diff --git a/debian/patches/series b/debian/patches/series
index df2364e..f5bf5b3 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
 20141103-disable-privacy-breach
 20141117-add-FL_CPP11-preprocessor-define
 20141117-add-kfreebsd-and-hurd-support
+20150204-let-vcmibuilder-be-case-insensitive

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/vcmi.git



More information about the Pkg-games-commits mailing list