Last active
October 1, 2018 17:37
-
-
Save DanielSundberg/a1f0895396ebd36bc497 to your computer and use it in GitHub Desktop.
AutoHotkey script to fix gerrit download url:s for Powershell
This file contains 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
; This script will take the url you get from | |
; the Gerrit download button and replace | |
; the unix command/line separator ('&&') with | |
; a ';' which is accepted as line break in | |
; PowerShell | |
; | |
; This works with Gerrit 2.9 on Windows/Firefox | |
; with Flash enabled | |
; | |
#Persistent | |
return | |
OnClipboardChange: | |
if SubStr(clipboard, 1, 9) = "git fetch" | |
{ | |
if InStr(clipboard, "some_other_url_element") > 0 | |
{ | |
FixString = %clipboard% | |
StringReplace, FixString, FixString,&&,;, All | |
clipboard:=FixString | |
ToolTip "Clipboard: " %FixString% | |
Sleep 1500 | |
ToolTip ; Turn off the tip. | |
} | |
} | |
return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment