A simple way to setup a new MacOS laptop/desktop for development, using just one command.
Note
This repository contains sysconfigs for my personal computer, please use these at your own risk!
To install, copy the below command and paste it in your terminal:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/sydrawat01/dotfiles/master/osx.sh)"
Clone this repository in your desired path using:
https://github.com/sydrawat01/dotfiles.git
To run the script to install all basic software with personal configs on your Mac, use this shell script: osx.sh
.
Although not required, provide exec permissions to this file, just to avoid any problems executing the shell script:
chmod +x osx.sh
Then, run the file:
./osx.sh
The GNU Stow is an open source project that helps maintain "symlink farms". I'm using it to maintain symlinks to my system configuration files that live in my $HOME
directory, mostly the .config/
, .zshrc
, .zshrc_aliases
, .tmux
, .vimrc
and other such application configs. This way, I have full control of my application settings, and can be synced across multiple devices since they are version controlled using Git.
Once all softwares are installed as in the previous step using the osx.sh
shell script, we need to install a couple of things manually before we can fully utilize stow
.
Install Node Version Manager
or nvm
, which is required by some Lua
packages for LazyVim
(in turn NeoVim
), this way we avoid any errors when using symlinks to setup NeoVim. With nvm
installed, we will then install the LTS version of node
, which will also install npm
for us.
brew install nvm
# check nvm
nvm --version
nvm install --lts
# check node and npm
node --version
npm --version
With this, we can now setup our dotfiles with stow
. If you have not already cloned this repository, do it now, and place it in a location where you want to manage your dotfiles from.
Now, let's run the stow
command to generate symlinks with the dotfiles
option, which is optimized for handling dotfiles symlinks.
# cd into the dotfiles folder.
cd ~/Developer/dotfiles
stow --dotfiles . --target=~/
The above command should automatically generate symlinks based on the folder structure (works with nested directories as well).
Important
The configs/
folder contains a backup of older configuration files from v2.x
, although VSCode setup requires the extensions.txt
file to setup the extensions. Other configurations are left as backup of older configs.
Warning
This is something subjective, so DevOps tools like Docker
, Kubernetes
, Kind
, Minikube
, Terraform
, Packer
, Ansible
etc., will be added to the install script in the future releases as per required. Note that the user will not be prompted to install/skip these tools, and will be installed regardless. In case these are required, I'll add a simple bash command to install these outside of the install script.
Install Devops related tools with homebrew
in the install script osx.sh
.