Skip to content

my wsl2, linux, MacOS (M2) dotfiles manged with chezmoi

Notifications You must be signed in to change notification settings

karnzx/dotfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

My dotfiles

my dotfiles managed with chezmoi

My setup

what I use
Operating System Window 11, WSL2 (Debian), MacBook M2 Pro
Shell ZSH (zsh4human)
dotfile manager chezmoi
editor neovim or vim or vi
password manager Bitwarden
etc. there a lot

Prerequisite

  • Linux or WSL2 etc.
  • ensure you can run window binary fix here
  • bitwarden data (keep sensitive files, only main branch)
  • curl

Make sure you have curl installed. If not, you can install it with the following command:

sudo apt install -y curl

Bitwarden CLI

To keep sensitive files away from the public repository, I use Bitwarden for added security. The following secrets are utilized within this setup.

If you don't use Bitwarden, just ignore any prompts during initialization with Chezmoi. see.

notes

name contain
dotfiles/.ssh/config_hosts ssh host configs

Window

Install Debian distribution or any you like

Open PowerShell or Windows Command Prompt in administrator mode and run.

wsl --install -d Debian

Tools

Install with Choco or Winget

Tools list

  • window terminal
  • vscode
  • putty
Choco

Install chocolatey see https://chocolatey.org/install

Open PowerShell as Administrator and run the following command:

choco.exe install -y microsoft-windows-terminal vscode putty
Winget
winget install -e --id Microsoft.WindowsTerminal
winget install -e --id Microsoft.VisualStudioCode
winget install -e --id PuTTY.PuTTY

MacOS

My Mac App Store Apps

I use MAS so these tools have to installed on apple account before.


Installation

To install chezmoi and clone the dotfiles in $HOME directory , use the bootstrap command below.

sh -c "$(curl -fsLS get.chezmoi.io)" -- init --apply karnzx

Optional variables so you can create for anyone who forks or clones these dotfiles for himself, leave it empty for manualy add

key value
BITWARDEN_EMAIL bitwarden email

The command works as follows:

  • Installs chezmoi, initializes it, and applies the dotfiles.
  • Once the dotfiles are cloned, chezmoi will run scripts to install all necessary things in .chezmoiscripts directory, such as WSL2 configuration, fonts, tools, etc.
  • apply chezmoi template, such as bitwarden get credential files

Updating your dotfiles

To update your dotfiles on any machine, use the following command (assuming cz is your chezmoi alias):

cz update

Looking for Just Dotfile Configs and Tools?

Are you looking for only dotfiles configs and tools without any secret files download from bitwarden? We've got you covered!

when installing there a prompt ark to install bitwarden, putty. just hit Enter


troubleshooting

WSL2 cant execute window binary

can not run cmd.exe or window program etc.

sudo sh -c 'echo :WSLInterop:M::MZ::/init:PF > /usr/lib/binfmt.d/WSLInterop.conf'

Interop Issue: unable to find interpreter for launching Windows .exe files using Interop

sudo update-binfmts --disable cli

then run following command on powershell

wsl.exe --shutdown

Releases

No releases published

Packages

No packages published