Skip to content

Commit

Permalink
Automate source distribution
Browse files Browse the repository at this point in the history
Just a quick-and-dirty shell script to automate some of the
things that cabal sdist doesn't quite handle
  • Loading branch information
lpsmith committed Jun 1, 2016
1 parent 297d2d6 commit a36e15f
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions sdist.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/bin/bash

echo "Generating CHANGELOG.md"
echo

cat <<HEADER > CHANGELOG.md
For the full changelog, see
<https://github.com/lpsmith/postgresql-simple/blob/master/CHANGES.md>
HEADER

perl -ne '$n++ if /^###/; exit if $n==2; print' CHANGES.md >> CHANGELOG.md

cat CHANGELOG.md
rm -f ./dist/*.tar
rm -f ./dist/*.tar.gz
cabal sdist
cd dist
wc *.tar.gz
gunzip *.gz
wc *.tar
zopfli *.tar
wc *.tar.gz
cd ..
rm -f ./dist/*.tar

0 comments on commit a36e15f

Please sign in to comment.