Skip to content
kisepichuPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

215 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dotfiles

Public chezmoi source for Windows, WSL Ubuntu, macOS, and NixOS dotfiles and agent workflows.

Fresh NixOS

NixOS provides git, curl, and mise as system packages and enables programs.nix-ld so mise's prebuilt Node binary can run. Clone this repository over HTTPS, then run the NixOS-only bootstrap from the checkout:

mkdir -p ~/repos
git clone https://github.com/kisepichu/dotfiles.git ~/repos/dotfiles
cd ~/repos/dotfiles
./scripts/bootstrap-nixos.sh

The bootstrap applies this chezmoi source non-interactively, which installs the declared mise tools (including Codex) and the omp and Claude Code CLIs under ~/.local/bin. Re-running it restores chezmoi-managed files to the repository state, so commit intentional local edits first. It does not perform any login or create credentials.

Create a dedicated GitHub key on the NixOS machine after the bootstrap:

mkdir -p ~/.ssh
chmod 700 ~/.ssh
ssh-keygen -t ed25519 -f ~/.ssh/id_ed25519_github_glaceon
cat ~/.ssh/id_ed25519_github_glaceon.pub

Register only the displayed public key in GitHub, then add this host entry to ~/.ssh/config:

Host github.com
  HostName github.com
  User git
  IdentityFile ~/.ssh/id_ed25519_github_glaceon
  IdentitiesOnly yes
chmod 600 ~/.ssh/config
ssh -T git@github.com

Complete the agent authentication manually on that machine:

codex login
claude login
# omp: start `omp`, then run /login

Fresh macOS

This path is for a Windows/WSL-first workflow on a new Mac. It is separate from the WSL bootstrap.

xcode-select --install
mkdir -p ~/repos
git clone https://github.com/kisepichu/dotfiles.git ~/repos/dotfiles
cd ~/repos/dotfiles
./scripts/bootstrap-macos.sh

After the script completes, open Karabiner-Elements once and grant the permissions requested by macOS.

Detailed notes: docs/macos-initial-setup.md

Fresh WSL Ubuntu

  1. Install WSL and Ubuntu from Windows.

    wsl --install -d Ubuntu
  2. Update WSL, then open the Ubuntu shell.

    wsl --update
  3. Clone this repository in WSL.

    sudo apt-get update
    sudo apt-get install -y git
    mkdir -p ~/repos
    git clone https://github.com/kisepichu/dotfiles.git ~/repos/dotfiles
    cd ~/repos/dotfiles
  4. Run the WSL bootstrap.

    ./scripts/bootstrap-wsl-ubuntu.sh
  5. Restart the shell after the bootstrap changes the default shell to fish.

    exec fish -l

Docker Engine On WSL

Install Docker Engine directly inside WSL Ubuntu when container-based project work is needed.

Docker Engine expects systemd in WSL. Current Ubuntu installs through wsl --install should use systemd by default; verify it when needed:

cat /proc/1/comm

If the output is not systemd, enable it inside the distro and restart WSL:

sudoedit /etc/wsl.conf

Add or update this section while preserving any existing settings:

[boot]
systemd=true
wsl --terminate Ubuntu

Replace Ubuntu with the distro name when it differs.

cd ~/repos/dotfiles
./scripts/install-docker-engine-wsl.sh

The script prompts before adding your user to the docker group. Accept only if you want to run Docker without sudo; Docker daemon access is effectively root-equivalent inside the WSL distro.

Then close and reopen the WSL session if you accepted the group change. Verify the install:

docker run --rm hello-world
docker compose version

If you declined the group change, use sudo for daemon access:

sudo docker run --rm hello-world
docker compose version

The script follows Docker's official Ubuntu apt repository flow and installs docker-ce, docker-ce-cli, containerd.io, docker-buildx-plugin, and docker-compose-plugin.

Nix (optional)

Nix is not part of the core bootstrap. Install it explicitly when a reproducible nix develop shell or optional Nix-managed tooling is wanted. The script uses the Determinate Nix Installer and supports macOS and WSL Ubuntu.

cd ~/repos/dotfiles
./scripts/install-nix.sh

On WSL, the script detects whether systemd is PID 1. If it is not (no systemd=true in /etc/wsl.conf), it installs with --init none so the install does not depend on a systemd-managed nix-daemon. For a systemd-managed daemon, enable systemd in WSL first (see the Docker section above).

Options:

  • NIX_INSTALL_NO_CONFIRM=1 runs the installer non-interactively.
  • NIX_INSTALL_DETERMINATE=1 installs Determinate Nix instead of upstream Nix.

Open a new shell after installing; conf.d/nix.fish sources the nix profile automatically. To uninstall a Determinate install:

/nix/nix-installer uninstall

Rust

Rust is managed by mise (declared in ~/.config/mise/config.toml). After chezmoi apply, mise install installs the toolchain and run_onchange_after_45-rust-components.sh.tmpl adds the rust-analyzer and rust-src components that neovim (rustaceanvim) needs. No manual step is required; open neovim in a Rust project and the LSP starts.

Agent CLIs

codex, claude, and omp are installed on every platform (macOS, WSL Ubuntu, NixOS) by chezmoi apply:

  • codex is declared in the mise tool list (~/.config/mise/config.toml) and resolves to the aqua:openai/codex prebuilt release binary. Upgrade it with mise up codex.
  • omp and claude are installed by run_after_50-install-agent-clis.sh from their upstream installers (https://omp.sh/install, https://claude.ai/install.sh) into ~/.local/bin.

That script runs on every apply and skips any CLI already on PATH, because both binaries update themselves (omp update, Claude Code's built-in updater). Their versions are deliberately not pinned here. A failed download warns instead of aborting chezmoi apply, and the next apply retries it — which is why this is not a run_once_ script.

Machines set up before this layout may hold a copy from an older channel. Remove it before the first apply, because the npm-installed claude occupies the same ~/.local/bin/claude path the installer would create: the script sees it, skips the install, and the later npm uninstall then leaves Claude Code absent. If the cleanup already ran after an apply, just run chezmoi apply again.

# macOS
brew uninstall --cask codex
# NixOS (installed by the old bootstrap)
npm --prefix ~/.local uninstall -g @openai/codex @anthropic-ai/claude-code

Authenticate once per machine; this repository stores no credentials.

codex login
claude login
# omp: start `omp`, then run /login

Neovim In Dev Containers

Use Neovim and this repository's Neovim config inside a project's dev container without changing the project. dcup (fish) runs devcontainer up with this repository as the dotfiles repository; the Dev Container CLI clones it into the container and runs scripts/install-devcontainer-neovim.sh once per container.

dcup                               # in the project directory
dcnvim                             # open Neovim in the container
dcup --remove-existing-container   # recreate the container to pick up dotfiles changes

The script installs Neovim, the tree-sitter CLI, Deno, ripgrep, fd, and the SKK dictionary, applies only ~/.config/nvim with chezmoi (no run_ scripts), and restores the plugins to lazy-lock.json. It supports apt-based (Debian/Ubuntu) glibc images, as root or with sudo. When the image moves XDG_CONFIG_HOME away from ~/.config, it links $XDG_CONFIG_HOME/nvim to the applied config.

devcontainer up still succeeds when the install script fails, so check its output for Neovim is ready in the dev container. Plugin download errors (for example, a dropped connection to GitHub) do not fail the script either. The script is safe to run again inside the container; it puts lazy-lock.json back and restores the plugins to it:

~/dotfiles/scripts/install-devcontainer-neovim.sh

The container gets the pushed config; edits made inside it stay in the container. To try unmerged changes, mount a local checkout into the container from the project side and point dcup at the container path, for example DCUP_DOTFILES_REPOSITORY=/path/in/container dcup. The CLI clones the checked-out branch of that path.

Project-specific settings, such as publishing the UI port that the CLI does not forward or mounting credentials (~/.wakatime.cfg), stay in the project's local, git-ignored configuration.

Validation

Before committing, run:

prek run --all-files

If prek is not available, run:

pre-commit run --all-files

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages