An open API service indexing awesome lists of open source software.

https://github.com/foiovituh/bakpak

A minimal Bash tool to compress any folder into a timestamped archive ๐Ÿ’พ
https://github.com/foiovituh/bakpak

backup backup-script backup-tool backup-utility bash-script cli-script cron shell-script targz

Last synced: 7 months ago
JSON representation

A minimal Bash tool to compress any folder into a timestamped archive ๐Ÿ’พ

Awesome Lists containing this project

README

          

# BakPak ๐Ÿ’พ
![GitHub License](https://img.shields.io/github/license/foiovituh/bakpak)

![Image](https://github.com/user-attachments/assets/cc4d443d-f1f2-4a34-8b59-f073e5ed0321)

A minimal Bash utility that turns any directory into a timestamped, compressed archive.

## Summary ๐Ÿ“
- [BakPak ๐Ÿ’พ](#bakpak-)
- [Summary ๐Ÿ“](#summary-)
- [Confirmed Working On โœ…](#confirmed-working-on-)
- [Installation ๐Ÿ“ฆ](#installation-)
- [Usage ๐Ÿš€](#usage-)
- [Automation โฐ](#automation-)
- [Do you want help me? ๐Ÿ‘ฅ](#do-you-want-help-me-)
- [License ๐Ÿณ๏ธ](#license-๏ธ)

## Confirmed Working On โœ…
| Component | Version / Notes |
| ----------- | -------------------------------------- |
| **Bash** | 5.2.21 (GNU) |
| **GNU tar** | 1.35 |
| **gzip** | 1.12 |
| **OS** | Ubuntu 24.04 (kernel 6.8.0-60-generic) |

## Installation ๐Ÿ“ฆ
```bash
# 1. Clone the repository
$ git clone https://github.com/foiovituh/bakpak.git
$ cd bakpak

# 2. Make the script executable
$ chmod +x bakpak.sh

# 3ย Install systemโ€‘wide
$ sudo ln -s "$PWD/bakpak.sh" /usr/local/bin/bakpak
```

## Usage ๐Ÿš€
Required:
```bash
-f Directory to back up (must be readable)
-t Directory to store the compressed archive (must be writable)
```

Optional:
```bash
-v Show script version
-h Show a help message
-u Uncompressed mode - create .tar archive
-d Dry-run mode โ€” no backups will be created, only displayed
```

Examples:
```bash
bakpak -f ~/Documents -t /mnt/docs_backup
bakpak -f ~/Tests -t /mnt/backup_simulations -d
bakpak -f ~/projects/president -t /mnt/d/band -p uncompressed_site_project -u
```

## Automation โฐ
Running a monthly backup at 5 PM on the 1st day of every month with `cron`:

```cron
0 17 1 * * /usr/local/bin/bakpak -f /home/president/Documents -t /mnt/backups
```

## Do you want help me? ๐Ÿ‘ฅ
If you have any ideas or wish to contribute to the project, contact me on X (@ohtoaki) or send me a pull request :)

## License ๐Ÿ“„
Distributed under the MIT License. See [`LICENSE`](LICENSE) for more information.