A modern, sustainable AUR package building and repository management tool for Arch Linux.
# Clone the repository
git clone https://github.com/joelgrun/archrepobuild
cd archrepobuild
# Set up virtual environment and install
python -m venv .venv
source .venv/bin/activate
pip install -e .
To build and install as a native system package:bash makepkg -si
To create a standalone executable that doesn't require Python:bash python scripts/build_binary.py
The binary will be available at dist/archrepobuild-bin.
Create configuration:bash cp config/config.example.yaml config.yaml # Edit config.yaml with your settings
Initialize repository:bash archrepobuild -c config.yaml init
Add packages:bash archrepobuild add yay paru
Build all packages:bash archrepobuild build-all
Build a specific package:bash archrepobuild build <package>
| Command | Description |
|---|---|
init |
Initialize repository directories |
add <packages...> |
Add and build new packages |
remove <packages...> |
Remove packages from repo |
build-all [-f] |
Build all packages, -f forces rebuild |
build <package> |
Build a specific package |
check |
Check for packages moved to official repos |
list |
List packages in repository |
remake |
Rebuild repository database |
cleanup |
Remove old package versions |
migrate-config <vars.sh> |
Migrate legacy config |
test-notifications |
Test notification setup |
See config/config.example.yaml for all options. Key settings:
repository:
name: "myrepo"
path: "/repo/x86_64"
build_dir: "/repo/build"
building:
parallel: true
max_workers: 4
retry_attempts: 3
retention:
keep_versions: 3
notifications:
email:
enabled: true
to: "admin@example.com"
archrepobuild migrate-config vars.sh -o config.yaml
Create /etc/systemd/system/archrepobuild.service:
```ini
[Unit]
Description=Build AUR packages
[Service]
Type=oneshot
ExecStart=/usr/bin/archrepobuild -c /etc/archrepobuild/config.yaml build-all
User=builduser
```
Create /etc/systemd/system/archrepobuild.timer:
```ini
[Unit]
Description=Run archrepobuild daily
[Timer]
OnCalendar=daily
Persistent=true
[Install]
WantedBy=timers.target
```
MIT