File: create_package

package info (click to toggle)
libvistaio 1.2.19-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 972 kB
  • sloc: ansic: 6,341; python: 41; makefile: 9; sh: 9
file content (10 lines) | stat: -rw-r--r-- 287 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
#!/bin/bash 
name=$1
version=$2 
pushd $3
if [ -d .git ]; then 
     git archive --format=tar  --prefix=${name}-${version}/ ${version} | xz -9 >$4/${name}-${version}.tar.xz 
else 
     echo "Sorry, package creation only works from a git repository, since it uses 'git archive'"
fi 
popd