27 lines
726 B
Bash
Executable File
27 lines
726 B
Bash
Executable File
set -e
|
|
|
|
cp -a /mu/pkg/$1 .
|
|
cd $1
|
|
[ -z "$2" ] || version="$(cat version)"
|
|
|
|
git clone --bare "$(cat url)" "git-bare"
|
|
cd "git-bare"
|
|
|
|
git worktree add -f "../git-worktree" $version
|
|
|
|
cd ../git-worktree
|
|
[ -n "$version" ] || git log | head -n1 | cut -d' ' -f2 > ../version
|
|
cd ..
|
|
printf %s\\t%s\\t%s\\t%s\\t%s\\n "$(cat version)" "$(cat type)" "arc" "$(expr $(du -sk git-worktree | cut -f1) \* 1024)" "$(cat sha512)">checks
|
|
printf %s\\t%s\\t%s\\t%s\\n "$(cat version)" "$(cat type)" "arc" "$(cat url)">urls
|
|
printf "version=\"$(cat version)\"\\ntype=\"$(cat type)\"\\n">defaults.sh
|
|
rm -fr git-bare git-worktree type url sha512 version patch inst.sh make.sh conf.sh pull.sh
|
|
|
|
echo "done!"
|
|
|
|
cat urls
|
|
echo
|
|
cat checks
|
|
echo
|
|
cat defaults.sh
|