devMachineSetup/README_SETUP_DEBIAN.md
2026-05-18 10:17:44 +12:00

40 lines
1.3 KiB
Markdown

Debian setup script
This repository contains a simple idempotent-ish script to provision a Debian-based machine after a rebuild.
Files
- setup-debian.sh: main script to run (creates/updates ~/.bashrc entries)
Usage
1. Make the script executable and run it as your user (it will use sudo when needed):
```bash
chmod +x ~/setup-debian.sh
~/setup-debian.sh
```
Optional: set your global Git identity during setup:
```bash
GIT_USER_NAME="Your Name" GIT_USER_EMAIL="you@example.com" ~/setup-debian.sh
```
or run with sudo:
```bash
sudo bash ~/setup-debian.sh
```
What the script does
- Updates apt and installs requested packages (curl, net-tools, ncdu, tmux, htop, nala, neofetch, nfs-common, git, neovim, etc.)
- Installs `snapd` and installs Bitwarden via snap
- Attempts to detect a unix socket (ssh/bitwarden) and export `SSH_AUTH_SOCK` to `~/.bashrc`
- Installs VS Code via snap
- Installs latest `kubectl` binary and enables bash completion + aliases (`k`)
- Adds a `fgk` alias for `flux get kustomizations all`
- Adds arrow-key history search (type prefix then Up/Down)
Notes
- The script attempts to detect a Bitwarden SSH agent socket but may not find it automatically depending on how Bitwarden exposes it; if needed, manually set `SSH_AUTH_SOCK` in your shell to the socket path.
- `flux` must be installed separately if you need `fgk` to work.