Skip to content

sei40kr/dotfiles

Repository files navigation

dotfiles

Made with Doom Emacs

Install

  1. Clone this repository:

    sudo git clone https://github.com/sei40kr/dotfiles.git /etc/dotfiles
    sudo chown -R $USER /etc/dotfiles
    ln -fs /etc/dotfiles ~/.dotfiles

Darwin

  1. Install Nix via multi-user installation (see Download Nix / NixOS):

    sh <(curl -L https://nixos.org/nix/install) --daemon
  2. Create a symlink from /run to /var/run:

    printf 'run\tprivate/var/run\n' | sudo tee -a /etc/synthetic.conf
    /System/Library/Filesystems/apfs.fs/Contents/Resources/apfs.util -B # For Catalina
    /System/Library/Filesystems/apfs.fs/Contents/Resources/apfs.util -t # For Big Sur and later
  3. Build the configuration with darwin-rebuild (if ./result/sw/bin/darwin-rebuild does not exist):

    cd ~/.dotfiles
    nix --extra-experimental-features 'nix-command flakes' build '.#darwinConfigurations.<host>.system'
  4. Switch to the new configuration:

    ./result/sw/bin/darwin-rebuild switch --flake '.#<host>'

NixOS

  1. Enter Nix shell (for the first time only):

    nix-shell
  2. Then, switch to the new configuration:

    nixos-rebuild switch --flake '.#<hostname>'

Things to Do Manually

Darwin

Install Homebrew

Some packages are installed via Homebrew. You need to install Homebrew manually first; otherwise, the installation of those packages will be skipped.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  • Generate a pair of SSH keys and add it to your GitHub account:

    ssh-keygen -t ecdsa
  • Install Google Chrome

  • Install Doom Emacs:

    git clone --depth 1 https://github.com/doomemacs/doomemacs ~/.emacs.d
    ~/.emacs.d/bin/doom install

Acknowledgements