Files
apf_portal/docs/setup/02-wsl-terminal-setup.md
T
Julien Gautier f70b1d3a1b
CI / commits (pull_request) Successful in 2m52s
CI / check (pull_request) Successful in 3m3s
CI / scan (pull_request) Successful in 3m11s
CI / a11y (pull_request) Successful in 3m5s
Docs site / build (pull_request) Successful in 3m10s
CI / perf (pull_request) Successful in 6m53s
docs(setup): add Debian 13 dev-VM setup procedure + scripts + devcontainer
New procedure in docs/setup/01-dev-debian-vm-setup.md targeting the new
dev VM (10.100.201.21, Debian 13) that replaces the WSL workflow. The
existing setup files are renumbered (01->02, 02->03, 03->04) to free
prefix 01 for the default flow.

10 modular idempotent scripts under docs/setup/scripts/ install the
stack: zsh + Oh My Zsh + Powerlevel10k + plugins, modern CLI tooling
(bat, eza, fd-find, ripgrep, fzf, zoxide, ncdu, keychain + dev extras),
nvm + Node from .nvmrc + corepack + pnpm, Docker CE + compose plugin,
inotify watches + swap + hostname tuning, best-effort UFW + sshd
hardening that probes-before-applying, and notes/aliases.zsh +
notes/gitconfig.txt installation.

A systemd template (apf-portal-infra@.service) auto-starts the local
dev infra stack at boot per user.

.devcontainer/ ships a VSCode Dev Container spec pinning Node 24 and
attaching to the host's apf-portal-dev Compose network so postgres /
redis / otel resolve by DNS from inside the container. initializeCommand
fails fast if the infra hasn't been brought up yet.

CLAUDE.md Environment conventions documents the two envs (local +
development) plus the hybrid sub-mode (workstation IDE + VM infra via
SSH LocalForward) and the two IDE flows (Remote-SSH + Devcontainer).

Adjacent follow-ups (not in this PR): preview infra on the GitLab VM
(10.100.201.10), GitLab Runner migration alongside the Gitea -> GitLab
cutover, private dotfiles repo.
2026-05-24 18:37:57 +02:00

1.8 KiB

🖥️ Modern WSL terminal (Zsh + Powerlevel10k)

Goal

A terminal that is:

  • readable
  • fast
  • equipped with intelligent autocomplete
  • suited for modern development

1) Install Zsh

sudo apt update
sudo apt install -y zsh

Set it as the default shell:

chsh -s $(which zsh)

Under WSL, add the following to ~/.bashrc:

if command -v zsh >/dev/null 2>&1; then
  exec zsh
fi

2) Install Oh My Zsh

sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

3) Install Powerlevel10k

git clone --depth=1 https://github.com/romkatv/powerlevel10k.git \
  ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/themes/powerlevel10k

In ~/.zshrc:

ZSH_THEME="powerlevel10k/powerlevel10k"

Then:

source ~/.zshrc
p10k configure

4) Install a Nerd Font (on Windows)

Install a Nerd Font on Windows (MesloLGS NF recommended).

Configure it in Windows Terminal:

  • Settings → Debian profile
  • Font → MesloLGS NF

5) Useful plugins

plugins=(
  git
  fzf
  zsh-autosuggestions
  zsh-syntax-highlighting
)

Install them:

git clone https://github.com/zsh-users/zsh-autosuggestions \
  ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions

git clone https://github.com/zsh-users/zsh-syntax-highlighting \
  ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

6) Modern CLI tools

sudo apt install -y \
  bat eza fd-find ripgrep fzf zoxide

Recommended aliases:

alias ls="eza --icons"
alias ll="eza -lh --git --icons"
alias cat="batcat"
alias grep="rg"
alias find="fdfind"

7) FZF

Add to ~/.zshrc:

[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh

Result

  • A modern terminal
  • Fast navigation
  • Higher productivity