aboutsummaryrefslogtreecommitdiff
blob: b69967b4ea7f8818b756cbef791445a295c32c9b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/bash

: ${TAR:=$(which tar)}

EXTRA_DIST="AUTHORS"
COMPLETION_WIDGETS="_eselect _gcc-config _genlop _gentoolkit _gentoo_packages _layman _portage _portage_utils"

snapshot_date="$(date +%Y%m%d)"
snapshot_dir="zsh-completion-${snapshot_date}"

if [[ -d ${snapshot_dir} ]]; then
	rm -rf ${snapshot_dir}
	mkdir ${snapshot_dir}
else
	mkdir ${snapshot_dir}
fi

for i in ${EXTRA_DIST}; do
	cp ${i} ${snapshot_dir}
done
for i in ${COMPLETION_WIDGETS}; do
	cp ${i} ${snapshot_dir}
done

${TAR} -Jcf ${snapshot_dir}.tar.xz ${snapshot_dir}