cat >> ~/.ssh/config <<EOF
Host *
IdentityFile ~/.ssh/id_rsa
AddKeysToAgent yes
EOFmkdir -p ~/Projects
git clone git@github.com:tungd/dotfiles-lean.git ~/Projects/dotfilesmkdir -p ~/.local/bin
ln -s ~/Projects/dotfiles/.bash_profile ~/.bash_profile
ln -s ~/Projects/dotfiles/.bashrc ~/.bashrc
ln -s ~/Projects/dotfiles/.emacs.d ~/.emacs.d
ln -s ~/Projects/dotfiles/.gitconfig ~/.gitconfig
ln -s ~/Projects/dotfiles/.npmrc ~/.npmrc
ln -s ~/Projects/dotfiles/.eslintrc ~/.eslintrcxcode-select --installThe global CLI profile is managed from this repo:
nix profile install ~/Projects/dotfiles/nix/profile
nix profile upgrade --impure nix-profileIt currently owns small standalone tools that should not be installed via MacPorts:
cloudflared direnv emacs-weekly fd fzf gh git-lfs htop jq opam ripgrep tmux tokei tree universal-ctags uv valkey wgetNo longer used; global tools moved to the Nix profile above.
The replacement is nix/profile/packages/emacs-weekly.nix.
cd /tmp
curl "https://s3.amazonaws.com/session-manager-downloads/plugin/latest/mac_arm64/sessionmanager-bundle.zip" -o "sessionmanager-bundle.zip"
unzip sessionmanager-bundle.zip
./sessionmanager-bundle/install -i ~/.local/lib/aws-ssm -b ~/.local/bin/session-manager-plugincurl -L https://raw.githubusercontent.com/qoomon/aws-ssm-ec2-proxy-command/master/aws-ssm-ec2-proxy-command.sh -o ~/.local/aws-ssm-ec2-proxy-command.sh
chmod +x ~/.local/aws-ssm-ec2-proxy-command.shcat >> ~/.ssh/config <<EOF
Host i-* mi-*
IdentityFile ~/.ssh/id_rsa
ProxyCommand aws ssm start-session --target %h --document-name AWS-StartSSHSession --parameters 'portNumber=%p'
StrictHostKeyChecking no
EOFDecrease repeat delay, increase repeat rate and disable Emoji.
defaults write -g ApplePressAndHoldEnabled -bool false
# defaults write -g InitialKeyRepeat -int 10
defaults write -g KeyRepeat -int 1
defaults write -g NSUserKeyEquivalents -dict-add 'Emoji & Symbols' '@^j'defaults write com.apple.screencapture disable-shadow -bool trueDisable font-smoothing, works better with 2k external display (provided web pages are zoomed & editors uses medium fonts)
defaults -currentHost write -g AppleFontSmoothing -int 2git clone https://github.com/jdtsmith/emacs-mac.git
cd emacs-macs
./autogen.sh
CFLAGS="-O3 -mcpu=native -mtune=native -fomit-frame-pointer -DFD_SETSIZE=10000 -DDARWIN_UNLIMITED_SELECT" ./configure --with-native-compilation=aot --with-tree-sitter --enable-mac-app=yes --prefix=$HOME/.local --with-modules --enable-mac-self-contained --without-dbus
make -j10
cp -R native-lisp mac/Emacs.app/Contents
make install
cp -R mac/Emacs.app ~/Applications