Skip to content

Mayurifag/.dotfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

411 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Setup environment cheatsheet

That is my dotfiles repository and little cheatsheet on how to setup my systems. It works on MacOS/Windows 11/CachyOS (Linux). Windows one differs from others, so I put it on another instruction file.

Preparation for MacOS

  • Update system. Install homebrew.
  • You will need to install homebrew' zsh and be sure you switched to it.
  • Setup iTerm2 like guake

Preparation for Linux

It mostly implies you should use KDE on Wayland.

  • Setup font: use JetBrains Mono Nerd Font 11pt for monospace and San Francisco font for other things.
  • Setup CapsLock to change layouts
  • KeepassXC with custom browsers requires Browser integration -> Advanced -> Use a custom browser configuration.
  • Setup ssh agent. Here will be working example for ArchLinux (btw) and Wayland KDE.
$ systemctl --user enable --now ssh-agent.service

# kate ~/.config/environment.d/ssh_vars.conf
SSH_AUTH_SOCK=${XDG_RUNTIME_DIR}/ssh-agent.socket

Make sure zsh is default shell: chsh -s /usr/bin/zsh. For Yakuake it will also require to setup/choose another profile, because default one is read-only.

  • Add user to input/uinput (for kanata):
sudo usermod -aG input "$USER"
sudo usermod -aG uinput "$USER"

Installation of environment

  • Set dracula theme everywhere you can, starting from terminal.
  • Go to KeepassXC and check that it works with ssh-agent. ssh-add -l has to print key which works with Github.
  • Install mise using your system manager.
sudo ln -s /Volumes/exfat/OpenCloud/Personal/Software/dotfiles/ejson /opt/ejson # or any other way to export your ejson key

Apply .dotfiles:

chezmoi cd
chezmoi init git@github.com:Mayurifag/.dotfiles.git --ssh
chezmoi diff # preview
chezmoi apply
  • Install packages for all languages and tools: make mise-packages

Things to do after

  • Authenticate GitHub CLI (token stored in OS keyring — same on macOS/Linux):
gh auth login
# → GitHub.com → SSH → Login with a web browser
  • Initiate sync on VSCode
  • Import and DO NOT FORGET ultimately TRUST gpg key:
IMPORT: gpg --import all-private-keys.asc
Check: gpg --list-secret-keys
Trust the imported key:

gpg --edit-key [key_id]
gpg> trust
  5 = I trust ultimately
Do you really want to set this key to ultimate trust? (y/N) y
gpg> quit
  • Install and configure gitkraken (ssh from system, etc.)
  • Setup external disks (router or else)
  • Setup Obsidian
  • Setup Browsers.app as default browser
  • Setup gsd - login. Perhaps also needed model/thinking levels, not sure

Sidenotes for MacOS

Paid macos apps I use (not in Brewfile)

  • Bartender
  • BetterSnapTool
  • Cleanshot
  • ...

Sidenotes for Linux

  • Run updatedesktopdb alias after installing arch-packages and chezmoi things.
  • Setup guake-like terminal and shortcuts
  • Install/copy windows fonts
  • Example of /etc/fstab entry for shared NTFS partition:
$ sudo -i
# mkdir /mnt/Shared
# kate /etc/fstab # CHANGE PARTUUID
PARTUUID="61ffcf10-e472-4c71-8e04-cf57c6463e6b" /mnt/Shared   ntfs3   \
uid=1000,gid=1000,umask=000,nofail,noatime,user,exec 0 0
# /etc/conf.d/wireless-regdom
WIRELESS_REGDOM="KR"
  • Prevent updating of gitkraken:
# /etc/pacman.conf
...
IgnorePkg = gitkraken
  • Enable native overlay diff engine to speed up building images in docker (info from ArchWiki):
$ kate /etc/modprobe.d/disable-overlay-redirect-dir.conf
options overlay metacopy=off redirect_dir=off
$ modprobe -r overlay
$ modprobe overlay
  • Activate docker socket and group
sudo systemctl enable --now docker.service
sudo groupadd docker # Check or create group docker
sudo gpasswd -a $USER docker
docker info # run docker info and check that Native Overlay Diff is true
  • Setup espanso
sudo setcap "cap_dac_override+p" $(which espanso) # for wayland
espanso service register
espanso start
  • Setup bluetooth (maybe dualboot)
  • Setup shortcuts:
Dolphin: Alt+E # a-la macos
Spectacle: Rectangular region on Alt+1 (Alt+!) # screenshot tool, I dont think I need other functions
Yakuake: Alt+`, Ctrl+` # terminal. Alt+` for a-la macos
Krunner: Meta+Space
# /boot/refind_linux.conf
"Boot using default options" "root=PARTUUID=13bbf375-9a9a-45cf-a256-3ea4f77ca6e0 rw nowatchdog zswap.enabled=0 amd_iommu=off transparent_hugepage=always numa_balancing=disable ttm.pages_limit=29360128 ttm.page_pool_size=25165824"
  • Instructions to use waystt as Speech-to-Text software:
sudo usermod -a -G input $USER
systemctl --user enable --now ydotool.service
echo '## Give ydotoold access to the uinput device
## Solution by https://github.com/ReimuNotMoe/ydotool/issues/25#issuecomment-535842993
KERNEL=="uinput", GROUP="input", MODE="0660", OPTIONS+="static_node=uinput"
' | sudo tee /etc/udev/rules.d/80-uinput.rules > /dev/null
waystt --download-model
# install playwright and enchant (not in archfile/npmfile)
sudo ln /usr/lib/libicudata.so /usr/lib/libicudata.so.66
sudo ln /usr/lib/libicui18n.so /usr/lib/libicui18n.so.66
sudo ln /usr/lib/libicuuc.so /usr/lib/libicuuc.so.66
sudo ln /usr/lib/libwebp.so /usr/lib/libwebp.so.6
sudo ln /usr/lib/libffi.so /usr/lib/libffi.so.7

Notes on repo

  • Repo is using ejson with keys.ejson file, which is needed to be reencrypted on changes:
ejson decrypt keys.ejson # or alias - dec
# edit ...
ejson encrypt keys.ejson # or alias - enc

TODO

About

macos/archlinux/windows dotfiles managed via chezmoi

Resources

Stars

Watchers

Forks

Contributors