bin/create_archive

9 lines
204 B
Plaintext
Raw Normal View History

2023-07-20 06:21:29 +02:00
#!/usr/bin/env zsh
# Create a tarball from given directory.
2023-09-01 14:15:45 +02:00
dir_name="$1"
archive_name="${dir_name}-$(date '+%Y%m%d').tar.gz"
tar cvfz "$archive_name" "$1" && \
echo "Created archive $archive_name"