[nodejs-cookie-signature] Update to upstream release 1.0.1

Jamie Nguyen jamielinux at fedoraproject.org
Wed Apr 17 08:46:05 UTC 2013


commit 5089faa2dd532ad15d779b848cc7503f9f81309b
Author: Jamie Nguyen <j at jamielinux.com>
Date:   Wed Apr 17 09:45:54 2013 +0100

    Update to upstream release 1.0.1

 .gitignore                   |    2 ++
 dl-tests.sh                  |   23 +++++++++++++++++++++++
 index-test.js                |   24 ------------------------
 nodejs-cookie-signature.spec |   15 +++++++++------
 sources                      |    3 ++-
 5 files changed, 36 insertions(+), 31 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index a30a85e..49a3c20 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,4 @@
 /cookie-signature-0.0.1.tgz
 /cookie-signature-1.0.0.tgz
+/cookie-signature-1.0.1.tgz
+/tests-1.0.1.tar.bz2
diff --git a/dl-tests.sh b/dl-tests.sh
new file mode 100755
index 0000000..83137ea
--- /dev/null
+++ b/dl-tests.sh
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+tag=1.0.1
+
+set -e
+
+tmp=$(mktemp -d)
+
+trap cleanup EXIT
+cleanup() {
+    set +e
+    [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp"
+}
+
+unset CDPATH
+pwd=$(pwd)
+
+pushd "$tmp"
+git clone https://github.com/visionmedia/node-cookie-signature.git
+cd node-cookie-signature
+git archive --prefix="test/" --format=tar tags/${tag}:test/ \
+    | bzip2 > "$pwd"/tests-${tag}.tar.bz2
+popd
diff --git a/nodejs-cookie-signature.spec b/nodejs-cookie-signature.spec
index 212a697..4c5d0c9 100644
--- a/nodejs-cookie-signature.spec
+++ b/nodejs-cookie-signature.spec
@@ -3,7 +3,7 @@
 %global enable_tests 1
 
 Name:       nodejs-cookie-signature
-Version:    1.0.0
+Version:    1.0.1
 Release:    1%{?dist}
 Summary:    Node.js module to sign and unsign cookies
 # License text is included in Readme.md
@@ -12,9 +12,10 @@ Group:      System Environment/Libraries
 URL:        https://github.com/visionmedia/node-cookie-signature
 Source0:    http://registry.npmjs.org/cookie-signature/-/cookie-signature-%{version}.tgz
 # The test files are not included in the npm tarball.
-# Source1 is retrieved from upstream version control repository:
-# wget https://raw.github.com/visionmedia/node-cookie-signature/master/index.js
-Source1:    index-test.js
+# Source1 is generated by running Source10, which pulls from the upstream
+# version control repository.
+Source1:    tests-%{version}.tar.bz2
+Source10:   dl-tests.sh
 BuildArch:  noarch
 
 BuildRequires:  nodejs-devel
@@ -30,8 +31,7 @@ BuildRequires:  npm(should)
 
 %prep
 %setup -q -n package
-mkdir -p test
-cp -p %{SOURCE1} test/index.js
+%setup -q -T -D -a 1 -n package
 
 
 %build
@@ -58,6 +58,9 @@ cp -pr package.json index.js \
 
 
 %changelog
+* Wed Apr 17 2013 Jamie Nguyen <jamielinux at fedoraproject.org> - 1.0.1-1
+- update to upstream release 1.0.1
+
 * Mon Apr 15 2013 Jamie Nguyen <jamielinux at fedoraproject.org> - 1.0.0-1
 - update to upstream release 1.0.0
 
diff --git a/sources b/sources
index a4c885c..30f9521 100644
--- a/sources
+++ b/sources
@@ -1 +1,2 @@
-0bfc00af376e6476be7d427d815dfb98  cookie-signature-1.0.0.tgz
+6e0f0533e0f6212b74d1fe993daac0dd  cookie-signature-1.0.1.tgz
+12b6c8a96f4c4e10745f3bf63543e1b2  tests-1.0.1.tar.bz2


More information about the scm-commits mailing list