Skip to content

Some dotfiles for PuTTY, Git, some Linux tools and Vim.

License

Notifications You must be signed in to change notification settings

cferriter/dotfiles

Repository files navigation

Dotfiles

This repo should be cloned to your home repo so that the path is ~/dotfiles/.

The makesymlinks.sh script creates symlinks from your home directory to the files which are located in ~/dotfiles/. The script will also back up existing dotfiles into ~/dotfiles_old/.

Prerequisites

  • rg must be installed for some of the Vim searching functionality. ripgrep.
  • xclip must be installed to copy text in tmux copy mode.
  • The editor to be used by git, and hence tig, must be set in the /etc/gitconfig file on a particular system.
  • Vim version 8 is required for the vim-gutentags plugin.
  • highlight is required for fancy preview of files using fzf.

Installation

git clone https://github.com/cferriter/dotfiles.git ~/dotfiles
cd ~/dotfiles
./makesymlinks.sh

Useful Links

Includes some repos used as inspiration.

Vim Plugins

vim-plug is used to install and manage the list of plugins below.

  • sensible.vim: Sensible .vimrc defaults.
  • Solarized Colorscheme for Vim.
  • fzf vim: Fuzzy searching tool (mainly used for file and tag searching).
  • ack.vim: Search tool which can make use of ripgrep.
  • vim-polyglot: A collection of language packs for Vim.
  • NERD Commenter.
  • vim-searchindex: Display number of search matches.
  • tig-explorer.vim: Jump to tig diff or blame view of current file.
  • Cscove: Attempts to find proper cscope database for current file and prompts cscope file creation when file not found. Also provides interface to cscope searches.
  • Gutentags: Automatic tag file regeneration.
  • sleuth.vim: Automatic detection of indent settings.
  • Visual Star Search: Use asterisk to search for visually highlighted text.
  • Vimwiki: Linked text files with custom syntax highlighting.
  • vimux: Interact with tmux from Vim shortcuts (mainly used for repeating the previous command in a tmux pane split with the current pane).
  • vim-qf: Scale quickfix window with Vim window height.

Configuring KiTTY

KiTTY is a fork of PuTTY with extra features. Most interestingly, it allows font size to be changed easily and dynamically. Steps to set up KiTTY are below.

  • Execute the PuTTY registry file in the repo by double-clicking on it in the Windows file explorer.
  • Download the "KiTTY Windows no compression" binary.
  • Rename the binary to KiTTY.exe.
  • Move the binary to C:\Program Files (x86)\KiTTY\KiTTY.exe.
  • Add the below KiTTY specific settings to the C:\Users\windows_username\AppData\Roaming\KiTTY\kitty.ini file.
; Decrease font size
fontdown={CONTROL}{F10}
; Increase font size
fontup={CONTROL}{F11}
; Switch to full screen
fullscreen={F11}
; special command box (default is CONTROL+F8)
input={CONTROL}{F8}

If your PuTTY registry file is updated and executed again, press CTRL+F8 in a KiTTY session and type /copytokitty.

Configuring Windows Terminal for SSH

Key-based authentication

Follow steps from this page: https://learn.microsoft.com/en-us/windows-server/administration/openssh/openssh_keymanagement

For the last step, "Deploying the public key", use the following command in PowerShell to deploy the public key onto a Linux machine:

type $env:USERPROFILE\.ssh\id_ed25519.pub | ssh user@hostname "cat >> .ssh/authorized_keys"