Skip to content

Instantly share code, notes, and snippets.

View NithinChintala's full-sized avatar
⚗️

Nithin Chintala NithinChintala

⚗️
View GitHub Profile
@backerman
backerman / profile-snippet-sshargcomplete.ps1
Last active July 16, 2024 15:05
Enable tab completion for ssh hostnames in PowerShell
using namespace System.Management.Automation
Register-ArgumentCompleter -CommandName ssh,scp,sftp -Native -ScriptBlock {
param($wordToComplete, $commandAst, $cursorPosition)
$knownHosts = Get-Content ${Env:HOMEPATH}\.ssh\known_hosts `
| ForEach-Object { ([string]$_).Split(' ')[0] } `
| ForEach-Object { $_.Split(',') } `
| Sort-Object -Unique
# For now just assume it's a hostname.
@sunaku
sunaku / set-option
Created October 31, 2013 04:19
Listing of all tmux 1.8 options vs. window options.
set-option [-agoqsuw] [-t target-session | target-window] option value
buffer-limit number
escape-time time
exit-unattached [on | off]
quiet [on | off]
set-clipboard [on | off]
Available session options are:
assume-paste-time milliseconds
base-index index
bell-action [any | none | current]