Watch
1
0
Fork
You've already forked dotfiles
0
No description
  • Shell 94.7%
  • Makefile 5.3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-04-03 17:13:19 +02:00
homefiles Refactoring project structure 2026-04-03 17:13:19 +02:00
scripts Refactoring project structure 2026-04-03 17:13:19 +02:00
.gitignore Update after applying Stow 2026-02-14 16:40:48 +01:00
LICENSE Initial commit 2026-02-12 21:43:44 +01:00
makefile Refactoring project structure 2026-04-03 17:13:19 +02:00
README.md Refactoring project structure 2026-04-03 17:13:19 +02:00

Dotfiles

This repository configures fresh macOS and Linux environments with GNU Stow.

Install

DOTFILES_PROFILE=<profile> curl -fsSL https://raw.githubusercontent.com/argael/dotfiles/main/scripts/install.sh | bash

The installer auto-detects the OS:

  • macOS: runs scripts/macos/install.sh
  • Linux: runs scripts/linux/install.sh

On a fresh macOS login, the installer first ensures Xcode Command Line Tools are installed (required for git). If macOS opens an installation dialog, complete it, then run the same command again.

You can override with:

  • DOTFILES_REPO
  • DOTFILES_BRANCH
  • DOTFILES_DIR
  • DOTFILES_PROFILE

Daily usage

make profiles
make git        # To install GIT configuration
make stow PROFILE=macos-pro
make restow PROFILE=linux-debian

Multi-environment profiles

The repository is now organized around strong profile entry points.

Profiles live in homefiles/profiles/*.packages and list the Stow packages to apply for a given environment, for example:

  • macos-pro
  • macos-perso
  • linux-debian
  • raspberry

Stowable packages now live in homefiles/packages/.

The intended layout is:

homefiles/
  packages/
    shared-shell/
    shared-tmux/
    macos-ghostty/
    macos-zed/
    macos-pro-shell/
    macos-perso-shell/
    linux-debian-shell/
    raspberry-shell/
  profiles/
    macos-pro.packages
    macos-perso.packages
    linux-debian.packages
    raspberry.packages

Profile packages are the entry points for each machine class:

  • each *-shell package owns its own .zshrc, .zprofile, and local example
  • shared-shell only contains reusable fragments under ~/.config/dotfiles/zsh/
  • app-specific packages like macos-ghostty and macos-zed stay separate
  • shared-tmux remains shared until a profile genuinely needs a different tmux config

Use a profile explicitly:

make profiles
make stow PROFILE=linux-debian
make restow PROFILE=raspberry
DOTFILES_PROFILE=macos-pro ./homefiles/stow-packages.sh stow

If no profile is provided, stow-packages.sh now fails fast instead of trying to merge incompatible entry points.

This favors:

  • explicit machine selection over implicit auto-merge
  • readable profile-specific shell entry files over deeply nested conditionals
  • reuse through sourced fragments only when the shared block is truly stable

Local secrets pattern (*.local)

Keep app configs tracked, and keep secrets in a local file that is not committed.

For Zed/OpenAI:

  1. Ensure homefiles/packages/macos-zed/dot-config/zed/settings.json has no api_key.
  2. Copy the matching dot-zshrc.local.example from your profile package to ~/.zshrc.local and set your real values:
export OPENAI_API_KEY="sk-..."
  1. Re-stow and reload shell:
make stow PROFILE=macos-pro
source ~/.zshrc

This keeps secrets out of Git while each profile keeps its own entry files.