[Pkg-bazaar-commits] ./bzr/unstable r699: - simpleminded patchwork client in shell

Martin Pool mbp at sourcefrog.net
Fri Apr 10 08:20:46 UTC 2009


------------------------------------------------------------
revno: 699
committer: Martin Pool <mbp at sourcefrog.net>
timestamp: Mon 2005-06-20 11:51:01 +1000
message:
  - simpleminded patchwork client in shell
added:
  contrib/pwk
-------------- next part --------------
=== added file 'contrib/pwk'
--- a/contrib/pwk	1970-01-01 00:00:00 +0000
+++ b/contrib/pwk	2005-06-20 01:51:01 +0000
@@ -0,0 +1,36 @@
+#! /bin/sh -pe
+
+# take patches from patchwork into bzr
+
+# authentication must be in ~/.netrc
+
+
+PWK_ROOT='http://patchwork.ozlabs.org/bazaar-ng'
+PWK_AUTH_ROOT='https://patchwork.ozlabs.org/bazaar-ng'
+
+usage() {
+    echo "usage: pwk cat PATCH-ID" >&2
+}
+
+catpatch() {
+    curl --get -d id=$1 $PWK_ROOT/patchcontent
+}
+
+if [ $# -ne 2 ]
+then
+    usage
+    exit 1
+fi
+
+
+case "$1" in
+cat)
+    catpatch $2
+    ;;
+try)
+    catpatch $2 | patch -p0 --dry-run
+    ;;
+*)
+    usage
+    exit 1
+esac
\ No newline at end of file



More information about the Pkg-bazaar-commits mailing list