diff --git a/LICENSE b/LICENSE
new file mode 100644
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,30 @@
+Copyright (c)2011, Henning Thielemann <darcs@henning-thielemann.de>
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+    * Redistributions of source code must retain the above copyright
+      notice, this list of conditions and the following disclaimer.
+
+    * Redistributions in binary form must reproduce the above
+      copyright notice, this list of conditions and the following
+      disclaimer in the documentation and/or other materials provided
+      with the distribution.
+
+    * Neither the name of Henning Thielemann <darcs@henning-thielemann.de> nor the names of other
+      contributors may be used to endorse or promote products derived
+      from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Setup.hs b/Setup.hs
new file mode 100644
--- /dev/null
+++ b/Setup.hs
@@ -0,0 +1,2 @@
+import Distribution.Simple
+main = defaultMain
diff --git a/cabal-darcs-bump-version b/cabal-darcs-bump-version
new file mode 100644
--- /dev/null
+++ b/cabal-darcs-bump-version
@@ -0,0 +1,6 @@
+nextversion=$1
+cabalfile=`echo *.cabal`
+
+perl -i -p -e 's/^( *(Version|Tag): *) (.+)/\1 '$nextversion'/i' $cabalfile
+
+darcs record -m "bump version to $nextversion" --no-test $cabalfile
diff --git a/cabal-darcs-repository b/cabal-darcs-repository
new file mode 100644
--- /dev/null
+++ b/cabal-darcs-repository
@@ -0,0 +1,11 @@
+lasttag=`darcs changes | grep tagged | head -n 1 | perl -p -e 's/ *tagged (.+)/\1/'`
+repo=`cat _darcs/prefs/defaultrepo`
+echo 'Source-Repository this'
+echo '  Tag:         '$lasttag
+echo '  Type:        darcs'
+echo '  Location:    '$repo
+echo
+echo 'Source-Repository head'
+echo '  Type:        darcs'
+echo '  Location:    '$repo
+echo
diff --git a/cabal-darcs-upload b/cabal-darcs-upload
new file mode 100644
--- /dev/null
+++ b/cabal-darcs-upload
@@ -0,0 +1,20 @@
+
+cabalfile=`echo *.cabal`
+
+name=`grep -i '^Name:' $cabalfile | perl -p -e 's/Name: *(.+)/\1/i'`
+
+version=`grep -i '^Version:' $cabalfile | perl -p -e 's/Version: *(.+)/\1/i'`
+nextversion=$1
+
+package=$name-$version
+
+cabal sdist && \
+cabal-test dist/$package.tar.gz && \
+\
+darcs tag $version && \
+\
+cabal upload dist/$package.tar.gz && \
+\
+cabal-darcs-bump-version $nextversion
+
+# darcs push
diff --git a/cabal-scripts.cabal b/cabal-scripts.cabal
new file mode 100644
--- /dev/null
+++ b/cabal-scripts.cabal
@@ -0,0 +1,75 @@
+Name:                cabal-scripts
+Version:             0.1
+License:             BSD3
+License-file:        LICENSE
+Author:              Henning Thielemann <darcs@henning-thielemann.de>
+Maintainer:          darcs@henning-thielemann.de
+Category:            Development
+Build-type:          Simple
+Cabal-version:       >=1.6
+Synopsis:            Shell scripts for support of Cabal maintenance
+Description:
+  This is a collection of Bash shell scripts
+  for support of Cabal package development.
+  The scripts are installed in your @cabal/share@ directory,
+  thus you may extend your command search path accordingly.
+  .
+  If you are in the directory of @mypkg@
+  (the directory that contains @mypkg.cabal@),
+  then you may run scripts in the following way:
+  .
+  * @cabal-test dist/mypkg-0.1.tar.gz@:
+    Unpack the tarball in the @/tmp@ directory
+    and try to build it using Cabal.
+    This check helps to find missing files in the Cabal package description.
+  .
+  * @cabal-darcs-bump-version 0.2@:
+    Replaces the package and the repository version number
+    in your Cabal file by 0.2
+    and records an according Darcs patch.
+  .
+  * @cabal-darcs-upload 0.2@:
+    This command supports the following workflow:
+    Say, on Hackage there is version 0.0.1 of your package
+    and the cabal file in the darcs repository says @Version: 0.1@.
+    Now you decide to finish that version
+    and to work next on the version 0.2.
+    This is the time when you call @cabal-darcs-upload 0.2@.
+    The call runs @cabal-test@ and @cabal check@ before uploading.
+    Then it tags the repository with the current package version number.
+    Then it uploads the package to Hackage.
+    Finally it bumps the version of the package to @0.2@.
+    This workflow makes sure,
+    that you never have two different contents for the same version
+    in Hackage and in your darcs repository.
+  .
+  * @cabal-darcs-repository@:
+    Shows some lines of @Source-Repository@ fields,
+    that you may copy into @mypkg.cabal@.
+    We fetch the repository URL from Darcs files.
+    Unfortunately, as developer
+    you will certainly use a private read-write access
+    to your repository like @code.haskell.org:\/home\/user\/mypkg\/@,
+    whereas the Cabal field may contain a public read-only access,
+    such as @http:\/\/code.haskell.org\/~user\/mypkg\/@.
+  .
+  See also package @cabal-sort@ that provides
+  the commands @cabal-sort@ and @ghc-pkg-dep@.
+
+Data-Files:
+  cabal-test
+  cabal-darcs-bump-version
+  cabal-darcs-repository
+  cabal-darcs-upload
+
+Source-Repository this
+  Tag:         0.1
+  Type:        darcs
+  Location:    http://code.haskell.org/~thielema/cabal-scripts/
+
+Source-Repository head
+  Type:        darcs
+  Location:    http://code.haskell.org/~thielema/cabal-scripts/
+
+Library
+  Build-Depends: base>=1 && <10
diff --git a/cabal-test b/cabal-test
new file mode 100644
--- /dev/null
+++ b/cabal-test
@@ -0,0 +1,16 @@
+
+package=`basename $1 .tar.gz`
+
+tar xfz ./dist/$package.tar.gz --directory=/tmp/
+cd /tmp/$package/
+runhaskell Setup configure --user --enable-tests
+runhaskell Setup build
+runhaskell Setup haddock
+
+echo
+echo "'cabal check' says"
+cabal check
+
+echo
+echo "After running tests you may want to call:"
+echo rm -r /tmp/$package/
