Created
January 22, 2020 17:41
-
-
Save hiphopsmurf/cfe74d4d89e98cd2eee7e6308582b9a5 to your computer and use it in GitHub Desktop.
Pageant Batch File for loading keys on startup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@ECHO off | |
REM Program : Pageant Key Loader | |
REM Author : Lee Robert | |
REM Description : Automatically loads specified private keys into | |
REM pageant on execution | |
REM ============================================================= | |
REM | |
REM Add a private key | |
IF EXIST "C:\path\to\your\key.ppk" (SET KEYS=%KEYS% "C:\path\to\your\key.ppk") | |
IF EXIST "C:\path\to\your\key2.ppk" (SET KEYS=%KEYS% "C:\path\to\your\key2.ppk") | |
IF NOT DEFINED KEYS EXIT | |
REM Change %PROGRAMFILES(X86)% to %PROGRAMFILES% if you do not have a Program Files (X86) folder | |
START /d "%PROGRAMFILES(X86)%\PuTTY" pageant.exe %KEYS% | |
EXIT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment