Skip to content

jazzabeanie/dotfiles

 
 

Repository files navigation

dotfiles

Ansible is not free anymore. Consider using salt - https://docs.saltproject.io/en/getstarted/

Prerequisites

Do I still need to do this?

touch ~/.gitconfig.local
# input your personal GitHub details into .gitconfig.local:
##################################
#[github]
#    user = GitHubUserName
#[user]
#    name = Your Name
#    email = [email protected]
##################################

Installing

OS X:

Linux:

  • SSH keys:

    • Copy existing keys, or create new ssh key and add to github
    • may also need to start the agent and add them there too.
      • eval "$(ssh-agent -s)"
      • ssh-add ~/.ssh/KEY_NAME
  • install git sudo apt install git curl zsh

  • git clone [email protected]:jazzabeanie/dotfiles.git ~/.dotfiles

  • Make Zsh the default shell chsh -s $(which zsh)

  • log out and log back in

  • install oh-my-zsh

  • Following Powerlevel10k getting started

  • reverse scroll direction

    • xfce: Mouse and Touchpad -> Reverse scroll direction
    • gnome
      • xinput --list to get ID of the mouse.
      • xinput set-prop pointer:"Logitech G300s Optical Gaming Mouse" "libinput Natural Scrolling Enabled" 1 to reverse the direction
      • Add this to startup applications so that it runs every time.
      • Make this run on startup by adding to ~/.profile?
  • install homebrew

  • run scirpts: (note, sudo not required)

    • ./setup_dotfiles.sh
    • ./setup_vim.sh
    • ./install_packages.sh
  • Swap CAPS and Ctrl, either:

  • install node (required for neovim):

    • install nvm
    • nvm install --lts
    • nvm use --lts
  • setup neovim: # TODO: put into homebrew script

  • Install alacritty

  • Install zsh-autosuggestions

  • Install fzf-tab git clone https://github.com/Aloxaf/fzf-tab ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tab

  • setup link to S3 bucket.

    • I'm using mountainduck on MacOS
  • install lazygit

    • brew install jesseduffield/lazygit/lazygit
  • install gron

    • download latest verion to /tmp/gron.tgz
    • extract with tar -xvzf /tmp/gron.tgz
    • move to /usr/local/bin: sudo mv /tmp/gron /usr/local/bin
  • install pip with get-pip.py script.

    • download the script to tmp, then run it with python3 /tmp/get-pip.py
  • install Joplin: wget -O - https://raw.githubusercontent.com/laurent22/joplin/dev/Joplin_install_and_update.sh | bash

  • Install 1Password

    • Also configure Ctrl+Shift+Space to open 1password instead of the quick access to enable password ignoring below.
  • setup CopyQ clipboard manager to ignore passwords:

    [Commands]
    1\Automatic=true
    1\Command="
        copyq ignore"
    1\Icon=\xf069
    1\Name=Ignore *1Password* windows
    1\Remove=true
    1\Window=.*1Password.*
    2\Automatic=true
    2\Command="
        copyq ignore"
    2\Icon=\xf069
    2\Input=x-kde-passwordManagerHint
    2\Name=Ignore Keepass window
    2\Remove=true
    size=2
    
  • sync my cheat fork

    • go to ()[https://github.com/jazzabeanie/cheatsheets] and sync fork
    • git clone https://github.com/jazzabeanie/cheatsheets.git ~/.config/cheat/cheatsheets/community/
    • the cheat config file (.dotfiles/home/cheat_config.yml) will need updating with the correct directory paths for the cheatsheets

Random Linux box:

  • this sets up .bashrc, aliases, and .vimrc. Run:
    • curl -o quick_setup.sh https://raw.githubusercontent.com/jazzabeanie/dotfiles/master/quick_basic_setup.sh
    • sudo chmod 755 quick_setup.sh
    • ~/quick_setup.sh
    • source ~/.bashrc

Windows:

  • reverse mouse scroll:
$devices = Get-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Enum\HID\*\*\Device Parameters" -ErrorAction SilentlyContinue | Where-Object { $_.FlipFlopWheel -ne $null }
foreach ($device in $devices) {
    # Reverse the scroll direction
    if ($device.FlipFlopWheel -eq 1) {
        Set-ItemProperty -Path $device.PSPath -Name "FlipFlopWheel" -Value 0
    } else {
        Set-ItemProperty -Path $device.PSPath -Name "FlipFlopWheel" -Value 1
    }
}
eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_ed25519
  • install wsl: wsl --install

    • Fix the DNS
      • in cmd: ipconfig/all
        • usually 10.10.32.50 in the office
      • update /etc/resolv.conf with the correct nameserver ip address (look for the fields labeled "DNS SERVERS" in the step above)
      • add the following to /etc/wsl.conf:
        • true means it will generate /etc/resolv.conf, but gives it the wrong nameserver so you have to change it manually every reboot. false means it will not generate the file and. Set it to false and copy the file sudo cp ~/.dotfiles/set_nameserver.sh /etc/profile.d/set_nameserver.sh
  • install winget packages

winget install --id Git.Git -e --source winget --interactive
winget install --id Joplin.Joplin -e --source winget --interactive
winget install --id Neovim.Neovim -e --source winget
winget install Microsoft.PowerToys -s winget
# QGIS?
sudo tee /usr/local/bin/xdg-open <<EOF
#!/bin/sh

powershell.exe -c start "'\$@'"
EOF
sudo chmod +x /usr/local/bin/xdg-open

Other tasks (not scripted)

About

Dotfiles

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 83.2%
  • Vim Script 8.1%
  • Python 7.2%
  • JavaScript 1.3%
  • Other 0.2%