blob: debc5195e4362a2aa444988bc6bc43c4d35cadf3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
#!/bin/bash
# Create target directory
cabal sdist
sdist_dir=$(basename dist/*.tar.gz .tar.gz)
rm -f dist/*.tar.gz
mkdir dist/$sdist_dir
find . \( -name .git -or -name dist -or -name cabal-dev \) -prune \
-or -not -name \\*.orig -not -type d -print \
| perl -ne 'print unless length >= 100' \
| xargs cp --parents --target-directory dist/$sdist_dir
cd dist
tar -caf $sdist_dir.tar.gz $sdist_dir
|