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

https://github.com/0zzz7y/backup

A set of lightweight Bash scripts for backing up and restoring workstation configurations and installing essential software.
https://github.com/0zzz7y/backup

backup-script bash

Last synced: about 1 month ago
JSON representation

A set of lightweight Bash scripts for backing up and restoring workstation configurations and installing essential software.

Awesome Lists containing this project

README

          

# Backup

A set of lightweight Bash scripts for backing up, restoring configurations, installing software and cleaning up the system.

---

## ✦ Backup Script

Backed up items:
- Flatpak apps list (`flatpaks.txt`)
- `~/.var/app`
- `~/.config`
- `~/.local/share`
- `~/.gitconfig`
- `~/.themes`
- `~/.icons`
- `~/.ssh`
- `~/.gnupg`
- GNOME/KDE settings via dconf (`dconf-settings.ini`)

---

### Usage

```bash
./backup.sh # Interactive backup
./backup.sh --all # Backup everything without prompts
./backup.sh --encrypt # Backup and encrypt with GPG symmetric encryption
./backup.sh --dir /path # Backup to custom directory (default: $HOME/Backup)
```

---

## ✦ Restore Script

Restored items:

* Flatpak apps list
* `~/.var/app`
* `~/.config`
* `~/.local/share`
* `~/.gitconfig`
* `~/.themes`
* `~/.icons`
* `~/.ssh`
* `~/.gnupg`
* GNOME/KDE settings via dconf (`dconf-settings.ini`)

---

### Usage

```bash
./restore.sh # Interactive restore from latest backup
./restore.sh --all # Restore everything without prompts
./restore.sh --decrypt file.tar.gz.gpg # Decrypt archive and restore from it
./restore.sh --dir /path # Restore from custom base backup directory
./restore.sh --from /path/to/backup # Restore from a specific backup directory
./restore.sh --dry-run # Preview restore actions without changes
```

---

## ✦ Install Script

Installs predefined packages via `dnf`, grouped by categories.

**Categories:**

* Development
* Editors
* Utilities
* Security
* Desktop
* Fonts
* Networking

---

### Usage

```bash
./install.sh # Interactive install
./install.sh --all # Install all without prompts
./install.sh --dry-run # Preview actions without making changes
```

---

## ✦ Cleanup Script

Cleans up files via bleachbit and custom cleanup scripts, grouped by categories.

**Categories:**

* BleachBit
* Package Manager
* Kernels
* Logs & Journals
* Snapshots
* Containers

---

### Usage

```bash
./cleanup.sh # Interactive cleanup
./install.sh --all # Cleanup all without prompts
./install.sh --dry-run # Preview actions without making changes
```

---

## ✦ Example Workflow

```bash
# Backup and encrypt everything
./backup.sh --all --encrypt

# Restore everything from encrypted archive
./restore.sh --decrypt ~/Backup/YYYYMMDD_HHmmSS.tar.gz.gpg --all

# Install essential software
./install.sh --all

# Cleans up unwanted files and software
./cleanup.sh --all
```

---

> Designed for Linux distro with Flatpak support.