dotfiles, software and configurations for Linux and macOS.
- Install applications using Homebrew.
- Setup terminal environment with Starship.
- Manage tool versions using mise.
- Configure Zsh with useful plugins and aliases.
- Configure Neovim and Visual Studio Code as modern IDEs.
- Setup programming languages C, C++, Go, Lua, Rust and TypeScript.
- Automatically update Homebrew applications (macOS only).
- Configure macOS default settings (macOS only).
The following list of prerequisites have to be met before you can install install these dotfiles.
- The shell is Zsh.
The output ofecho $SHELLshould end withzsh, e.g./bin/zsh. If this isn't the case, you can change the shell with e.g.chsh -s /bin/zshand reopen the terminal to use the new shell. - The following software is installed and available in the
PATH.
Caution
Use at your own risk! These dotfiles install software and update macOS settings. Always read the code and settings before using these dotfiles. These dotfiles are only tested and used on the latest macOS version.
Install the dotfiles using Git and the installation script. The dotfiles will be installed in $HOME/.config/dotfiles and linked to the HOME directory as needed. During the the synchronisation step of the installation, non-excluded files will be deleted from the destination directory, $HOME/.config/dotfiles, to prevent lingering dotfiles. Please see the Usage sections for customisations before installing.
$ git clone https://github.com/jdbruijn/dotfiles.git
$ cd dotfiles
$ ./installSome manual steps might still be required, depending on your desired setup and configuration, after the installation. In the docs directory there is documentation for the steps I have taken for my own configuration, which contains the following.
Using the Install steps, you'll get exactly the setup I have myself. You can, however, add custom configurations to these dotfiles. The configurations can be extended using the custom/ directory, which will be synchronised to $HOME/.config/dotfiles/custom/, or directly in the $HOME/.config/dotfiles/custom/ directory. Using either directory, the synchronisation step of the installation will honour your custom configuration and not delete any of the files in these directories. This means that files in the $HOME/.config/dotfiles/custom/directory will not be removed by the synchronisation, so you're responsible for removing files you no longer use.
In the custom/install file, which must be executable, you can specify custom installation steps that will be run after all other installation steps. You can use this to install and configure additional software or change configurations, e.g. add different applications to the Dock as shown in the following example.
Custom installation example
#!/bin/sh
# Wipe all, default, app icons.
defaults write com.apple.dock persistent-apps -array
defaults write com.apple.dock persistent-others -array
# Dock apps.
. "${DOTFILES}/macos/dock-app"
dock_app '/Applications/1Password.app'
dock_app '/Applications/Google Chrome.app'
dock_app "/Applications/Ghostty.app"
dock_app "/Applications/Notion.app"
dock_app '/Applications/Sequel Ace.app'
dock_app '/Applications/Visual Studio Code.app'
killall -q Dock
sleep 1Custom Homebrew configurations
The Homebrew configuration, specifically which packages are installed, can be customised using the custom directory and the DOTFILES_BREWFILE environment variable. When the DOTFILES_BREWFILE environment variable is set when doing the Install, the homebrew/Brewfile file will not be used for the command to install Homebrew packages and the file referenced by DOTFILES_BREWFILE will be used instead. This allows you to configure exactly which Homebrew packages you want to install and where to install casks. The following list of packages are still required to be included in your custom list of Homebrew packages. This is not enforced by the installation though. If you don't include these Homebrew packages, you likely get errors and/or weird behaviour in the terminal.
bat- Acatclone with syntax highlighting and Git integration.cmake- A powerful software build system, de-facto standard for building C++ code.eslint_d- A deamon for ESLint, a tool to find and fix problems in your JavaScript code.eza- A modern replacement forls.fzf- A general-purpose command-line fuzzy finder.llvm- A collection of modular and reusable compiler and toolchain technologies.lua-language-server- A language server that offers Lua language support.make- A tool which controls the generation of executables and other non-source files of a program from the program's source.mise- A development environment setup tool.ninja- A small build system with a focus on speed, for use with CMake.prettierd- A daemon for Prettier, an opinionated code formatter.ripgrep- A line-oriented search tool that recursively searches the current directory for a regex pattern.starship- The minimal, blazing-fast, and infinitely customizable prompt for any shell!stylua- An opinionated Lua code formatter.zoxide- A smartercdcommand.zsh-autosuggestions- Fish-like fast/unobtrusive autosuggestions for Zsh.zsh-syntax-highlighting- Fish shell-like syntax highlighting for Zsh.
For macOS, the following list of casks are still required to be included in your custom list of Homebrew packages.
font-fira-code-nerd-font- A monospaced font with programming ligatures with Nerd Fonts patches.raycastcask - A collection of powerful productivity tools all within an extendable launcher.secretivecask - A fully native Mac app that lets you protect and manage SSH keys with your Mac's Secure Enclave.shottrcask - A tiny and fast mac screenshot tool with annotations, beautiful backgrounds, scrolling screenshots and cloud upload capabilities.
The following command is an example of using the custom/homebrew/Brewfile for the installation.
DOTFILES_BREWFILE="${HOME}/.config/dotfiles/custom/homebrew/Brewfile" ./installCustom Zsh configurations
The Zsh configuration can be extended using the custom/zsh/ directory, where you can place additional Zsh files. path.zsh files in the this directory are sourced at the beginning of the Zsh configuration. These files should only be used to export the PATH.
Git configuration
For the Git user configuration, please create a new .gitconfig.local file in your home directory. You can use the git/.gitconfig.local file as a template and update it's contents.
To update the dotfiles, pull the latest changes and run the installation script again. The installation is idempotent, making it possible to use the installation script for updates as well. The DOTFILES_SYNC_ONLY environment variable can be set to skip all installation steps, including the Custom installation, and only synchronise the files.
$ git pull
$ ./install
# Alternative call of the install script, only synchronising the files.
$ DOTFILES_SYNC_ONLY=1 ./installFormulae installed with Homebrew, including casks, will be automatically updated using Homebrew Autoupdate. If you do not wish to update casks automatically, you can add unset HOMEBREW_UPGRADE_GREEDY using the Custom Zsh configurations.
Please create an issue if you have a bug report or feature proposal, or create a discussion if you have a question. If you like this project, please consider giving it a star ⭐
Refer to the contributing guide for detailed information about other contributions, like pull requests.
Please refer to the Security Policy on GitHub for the security policy.
This project is licensed under the GPLv3 license.
Copyright © 2024-2025 Jeroen de Bruijn
License notice
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
The full text of the license is available in the LICENSE file in this repository and online.