Skip to content

Instantly share code, notes, and snippets.

View glsorre's full-sized avatar

Giuseppe Sorrentino glsorre

View GitHub Profile
glsorre / keychain.ps1
Last active May 23, 2022 05:23
Windows Subsystem for Linux: never prompt ssh passphrase again
View keychain.ps1
$credentials = Get-StoredCredential -Target sshpassphrase
$BSTR = [System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($credentials.Password)
$passphrase = [System.Runtime.InteropServices.Marshal]::PtrToStringAuto($BSTR)
C:\Windows\System32\wsl.exe -u [YOUR_WSL_USERNAME] -d [YOUR_DISTRIBUTION] /home/[YOUR_WSL_USERNAME]/wslu/ $passphrase
glsorre / .gitignore
Last active July 2, 2021 02:27
A functional boilerplate for with creeps based on the fsm pattern