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

https://github.com/ndxdeveloper/uubu

๐Ÿš€ Automated system update tool for Ubuntu/Kubuntu - Updates APT, Snap, Flatpak with optional Timeshift snapshots
https://github.com/ndxdeveloper/uubu

apt automation cli-tool devops flatpak golang kubuntu linux package-manager snap system-administration system-update timeshift ubuntu

Last synced: 3 days ago
JSON representation

๐Ÿš€ Automated system update tool for Ubuntu/Kubuntu - Updates APT, Snap, Flatpak with optional Timeshift snapshots

Awesome Lists containing this project

README

          

# uubu ๐Ÿš€

**Update Upgrade Ubuntu** - An automated system update tool for Ubuntu/Kubuntu written in Go.

[![Go Report Card](https://goreportcard.com/badge/github.com/NDXdeveloper/uubu)](https://goreportcard.com/report/github.com/NDXdeveloper/uubu)
[![Release](https://img.shields.io/github/release/NDXdeveloper/uubu.svg)](https://github.com/NDXdeveloper/uubu/releases)

## ๐Ÿ“‹ Description

`uubu` automates comprehensive system updates for Ubuntu-based distributions. It handles APT packages, Snap packages, Flatpak applications, system cleanup, and offers optional Timeshift snapshots for safe rollback.

## โœจ Features

- ๐Ÿ”„ **Complete System Updates**: APT, Snap, and Flatpak packages
- ๐Ÿ“ธ **Timeshift Integration**: Optional system snapshots before updates
- ๐Ÿงน **Automatic Cleanup**: Removes obsolete packages and cleans cache
- ๐Ÿ”’ **Safety Checks**: Root prevention, internet connectivity verification
- ๐ŸŽจ **Colored Output**: Clear, colored terminal messages
- โšก **Fast & Lightweight**: Single binary with no dependencies
- ๐Ÿ”ง **Configurable**: Flexible command-line options

## ๐Ÿš€ Quick Start

### Installation

#### From Release (Recommended)
```bash
# Download latest release
wget https://github.com/NDXdeveloper/uubu/releases/latest/download/uubu-linux-amd64
chmod +x uubu-linux-amd64
sudo mv uubu-linux-amd64 /usr/local/bin/uubu
```

#### From Source
```bash
git clone https://github.com/NDXdeveloper/uubu.git
cd uubu
make build
make install
```

### Usage

```bash
# Basic system update
uubu

# Update with Timeshift snapshot
uubu -s

# Update without Snap packages
uubu --no-snap

# Update with full system upgrade
uubu --dist-upgrade

# Show help
uubu --help

# Show version
uubu --version
```

## ๐Ÿ“– Command Line Options

| Option | Description |
|--------|-------------|
| `-h, --help` | Display help information |
| `-v, --version` | Show version information |
| `-s, --snapshot` | Create Timeshift snapshot before update |
| `--dist-upgrade` | Perform full system upgrade (includes removing obsolete packages) |
| `--no-snap` | Skip Snap package updates |
| `--no-flatpak` | Skip Flatpak package updates |
| `--no-reboot` | Don't prompt for reboot |

## ๐Ÿ› ๏ธ What uubu Does

1. **System Checks**: Verifies non-root execution and internet connectivity
2. **Optional Snapshot**: Creates Timeshift snapshot if requested
3. **APT Updates**: Updates package lists, upgrades packages, dist-upgrade
4. **Snap Updates**: Refreshes Snap packages (if installed)
5. **Flatpak Updates**: Updates Flatpak applications (if installed)
6. **System Cleanup**: Removes obsolete packages and cleans cache
7. **Reboot Check**: Detects if reboot is required and prompts user

## ๐Ÿ“‹ Requirements

- Ubuntu 20.04+ or Kubuntu 20.04+
- Go 1.19+ (for building from source)
- sudo privileges for system updates
- Optional: Timeshift (for snapshots)

## ๐Ÿ”ง Development

### Building

```bash
# Clone repository
git clone https://github.com/NDXdeveloper/uubu.git
cd uubu

# Build with version info
make build

# Run tests
make test

# Check code coverage
make test-coverage

# Development mode (auto-rebuild)
make dev
```

### Testing

```bash
# Run all tests
make test

# Run tests with race detection
make test-verbose

# Quick tests (no integration)
make test-short

# Benchmarks
make bench
```

## ๐Ÿ“ฆ Project Structure

```
uubu/
โ”œโ”€โ”€ main.go # Main application
โ”œโ”€โ”€ main_test.go # Unit tests
โ”œโ”€โ”€ Makefile # Build automation
โ”œโ”€โ”€ go.mod # Go module file
โ”œโ”€โ”€ README.md # This file
โ””โ”€โ”€ LICENSE # MIT license
```

## ๐Ÿšฆ Safety Features

- **Root Prevention**: Refuses to run as root user
- **Internet Check**: Verifies connectivity before updates
- **Error Handling**: Graceful handling of command failures
- **Snapshot Support**: Optional system backup via Timeshift
- **Reboot Detection**: Warns when restart is required

## ๐Ÿค Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

1. Fork the project
2. Create your feature branch (`git checkout -b feature/AmazingFeature`)
3. Commit your changes (`git commit -m 'Add some AmazingFeature'`)
4. Push to the branch (`git push origin feature/AmazingFeature`)
5. Open a Pull Request

## ๐Ÿ“ License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

## ๐Ÿ‘ค Author

**Nicolas DEOUX**
**NDXDev** (NDXDev@gmail.com)

## ๐Ÿ™ Acknowledgments

- Original bash script inspiration
- Ubuntu/Kubuntu community
- Go programming language team

---

โญ **Star this repository if you find it useful!**