PortingOver

Main.ks v0.09

Jun 22nd, 2026
64
0
238 days
3
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Autohotkey 15.31 KB | Software | 0 0
  1. ; v0.09 Added +Insert for manual typing out of clipboard
  2. ; v0.08 Commented out Outside_of_browser lines
  3. ; v0.07 Removed BlockInput and made a workaround for script-reloading
  4. ; v0.06 Removed !. Emote shortcut due to already having it in Keyboard
  5. ; v0.05 Added ~ to #Space
  6. ; v0.04 Attempted to add !s to Terminal
  7. ; v0.03 Added Cortile conditional auto-start
  8. ; v0.02 Added MsgBox confirmation to Audacity normalization script
  9. ; v0.01 Initialization
  10.  
  11. ; Tasks:
  12. ; Add GIMP plugin hotkey
  13.  
  14. #Persistent
  15. #SingleInstance Force
  16.  
  17. #HotIf WinActive('ahk_exe xed') ; If the Xed text editor is the currently active window
  18. ~^s::{ ; Press Ctrl+S
  19.     Reload
  20. ;    Run(A_ScriptFullPath) ; In case Reload fails: run another instance of this script
  21. ;    ExitApp ; Close this script
  22. }
  23. #HotIf
  24.  
  25. ;^Alt::^PgDn
  26. ;^LWin::^PgUp ; malfunctions and disables the Super key!
  27.  
  28. !/::Send '{AppsKey}' ; Press Alt + /
  29.  
  30. ~$#Space:: { ; Press Super+Space
  31.     WinWaitActive('ahk_exe nemo') ; Waits for Nemo to launch (keyboard custom shortcut)
  32.     If (A_ComputerName = 'LMC-R10') {
  33.         Sleep 450
  34.         Send '^l/media/' . A_Username . '/Seagate-ext4{Enter}' ; cd to the Seagate's ext4 partition
  35.         Sleep 250
  36.     }
  37.     Send '^f' ; Presses Ctrl+F
  38.     SoundBeep
  39. }
  40.  
  41. ; ===== Browsers
  42.  
  43. GroupAdd 'browsers', 'Google Chrome'
  44. GroupAdd 'browsers', 'Microsoft Edge'
  45. GroupAdd 'browsers', 'Firefox'
  46. GroupAdd 'browsers', 'Floorp'
  47. GroupAdd 'browsers', 'Waterfox'
  48. GroupAdd 'browsers', 'LibreWolf'
  49. GroupAdd 'chromium', 'Google Chrome'
  50. GroupAdd 'chromium', 'Microsoft Edge'
  51. GroupAdd 'mozilla', 'Firefox'
  52. GroupAdd 'mozilla', 'Floorp'
  53. GroupAdd 'mozilla', 'Waterfox'
  54. GroupAdd 'mozilla', 'LibreWolf'
  55.  
  56. ;#HotIf WinActive('ahk_group browsers')
  57. ~MButton::{ ; Hold down the scroll wheel for 0.35 sec to close the current tab
  58.     Sleep 350
  59.     If (not WinActive('Tinkercad')) && GetKeyState('MButton') ; If the middle mouse button is still held down
  60.         Send '{Escape}^w'
  61. }
  62. ;#HotIf
  63.  
  64. #HotIf WinActive('ahk_group mozilla')
  65.  
  66. !z::{ ; Enter Mozilla browser tab-searching mode
  67.     Send '^l'
  68.     Sleep 250
  69.     Send '{bs}%{space}'
  70. }
  71.  
  72. #HotIf WinActive('WhatsApp') ; Adapt find command for WhatsApp
  73. ^f::!k
  74. #HotIf
  75.  
  76. #HotIf WinActive('Software Manager')
  77. !Left::'{bs}'
  78. #HotIf
  79.  
  80. ; =====
  81.  
  82. #HotIf WinActive('Signal') ; If Signal is the active window
  83. ~$+Control::^+t ; Press Shift+Ctrl to focus on the text field
  84. #HotIf
  85.  
  86. F1::{
  87.     If WinActive('ahk_exe' 'Audacity') {
  88.         result := MsgBox('Normalize this whole track? (Must be in Audacity)',, 'YesNo')
  89.         If (result = 'No')
  90.             Return
  91.         Send '^a'
  92.         Sleep 500
  93.         Send '!c'
  94.         Sleep 500
  95.         Send '{Down 2}'
  96.         Sleep 500
  97.         Send '{Enter 3}'
  98.     }
  99.     Else {
  100.         MouseGetPos(&LocationX, &LocationY)
  101.         A_Clipboard := "MouseClick('L', A_ScreenWidth*" . LocationX . '/' . A_ScreenWidth . ', A_ScreenHeight*' . LocationY . '/' . A_ScreenHeight . ') `; Pixel Color: ' . PixelGetColor(LocationX,LocationY)
  102.         ToolTip LocationX . 'x' . LocationY . ' (mouse), ' . A_ScreenWidth . 'x' . A_ScreenHeight . ' (screen)`nCopied KS click coordinates + pixel color ' . PixelGetColor(LocationX,LocationY) . ' to the clipboard.'
  103.         SetTimer () => ToolTip(), -10000
  104.         LocationX := "" ; Clear memory
  105.         LocationY := ""
  106.     }
  107. }
  108.  
  109. ;Use "EncodeDecodeURI(clipboard, false)" to decode or "(clipboard, true)" to encode the URL in the clipboard
  110. EncodeDecodeURI(str,encode:=True,component:=True){
  111. #import Ks { Clr } static Web := Clr.Load("System.Web.HttpUtility") return Web.HttpUtility.Url%(encode?"en":"de")%code(str)
  112. }
  113.  
  114. PurgeClipboardURL() { ; Remove all known trackers and change WWW Reddit links to Old
  115.     keep_question_marks := ""
  116.     A_Clipboard := A_Clipboard ; Convert to plain text
  117.     If InStr(A_Clipboard, ' › ') ; Convert Bing's spaced carets to slashes
  118.         A_Clipboard := StrReplace(A_Clipboard, ' › ', '/')
  119.     If InStr(A_Clipboard, '%') ; Decode the encoded URL
  120.         A_Clipboard := EncodeDecodeURI(A_Clipboard, false)
  121.     If InStr(A_Clipboard, 'http://') ; Force HTTPS
  122.         A_Clipboard := StrReplace(A_Clipboard, 'p', 'ps')
  123.     If InStr(A_Clipboard, '://www.reddit.com') ; Force all Reddit links to Old Reddit {
  124.         A_Clipboard := StrReplace(A_Clipboard, '://www', '://old')
  125.     Else if InStr(A_Clipboard, '://reddit.com')
  126.         A_Clipboard := StrReplace(A_Clipboard, '://', '://old.')
  127.  
  128.     prefixes := ['//click.alert.ally.com/CL0/', 'https://www.ojrq.net/p/?return=', 'ref=notif&']
  129.     For each, prefix in prefixes
  130.         If InStr(A_Clipboard, prefix) { ; Delete any found prefixes
  131.             A_Clipboard := StrReplace(A_Clipboard, prefix)
  132.             break
  133.         }
  134.  
  135.     If InStr(A_Clipboard, 'instagram.com/_u/') ; Remove "/_u" if present
  136.         A_Clipboard := StrReplace(A_Clipboard, '/_u')
  137.     If InStr(A_Clipboard, 'bing.com') ; Purge Bing URLs of trackers between "form=" and "q="{
  138.         A_Clipboard := RegExReplace(A_Clipboard, '(form=).*(&q=)', 'q=')
  139.     Else if not (InStr(A_Clipboard, 'indeed.com') or InStr(A_Clipboard, 'ebay') or InStr(A_Clipboard, '&uu='))
  140.         A_Clipboard := RegExReplace(A_Clipboard, ".*?(u=|q=|url=)") ; Attempt to delete prefix redirectors: everything before "u=", "q=", etc.
  141.     If InStr(A_Clipboard, '%') ; Decode the encoded URL again
  142.         A_Clipboard := EncodeDecodeURI(A_Clipboard, false)
  143.  
  144.     If InStr(A_Clipboard, '?') { ; If the clipboard contents include a question mark
  145.         whitelist := ['?post_id=', 'musicnotes.com','humblebundle.com/?key=', 'soundgym.co', 'walgreens.com', 'boardgamearena.com', 'indeed', 'youtube', 'abcnews.go', 'piped.video', 'play.google.com', 'linkedin.com/jobs/search/?currentJobId', 'bing.com', '?profile_id=', 'profile.php?id=', '?fbid=', ' ?obId=', 'cloudskillsboost.google', '?notif_id=', 'multi_permalinks', '?_nkw=', 'node=', 'rlkey=', 'schafffuneralhome.com', 'churchandchapel.com', 'bvfh', 'google.com/calendar/embed', 'beckerritter.com', '?story_fbid=', 'productName=CONSUMER_DEBIT_CARD', 'finviz.com', '.amazon.com/your-orders/order-details?orderID=', '/referral?referralCode=', '.facebook.com/watch/live/', 'amazon.com/gp/css/summary/print.html?orderID=', '.facebook.com/watch/?v=', '.redcrossblood.org/give.html/drive-results?'] ; rlkey is a Dropbox file access key; productName is a PayPal URL thing
  146.         For exception in whitelist { ; Check whitelist entries one by one
  147.             If InStr(A_Clipboard, exception) {
  148.                 If (InStr(A_Clipboard, 'similar-jobs?currentJobId=') or !InStr(A_Clipboard, '?si=') or !InStr(A_Clipboard, '.youtube.com/channel/')) ; If the clipboard's contents contain the currently checked exception
  149.                     keep_question_marks := 1
  150.                     global_exception := exception
  151.                     break
  152.             }
  153.         }
  154.  
  155.     If InStr(A_Clipboard, 'node=') or InStr(A_Clipboard, 'Namecheap') { ; If this is a Namecheap or Amazon node link
  156.         TrayTip('If it`'s always followed by "&ref_", adjust the URL purger to delete that and everything else','Check for possible Amazon node or Namecheap package link!')
  157.         A_Clipboard := StrSplit(A_Clipboard, "&utm")[1]
  158.     }
  159.     Else If (keep_question_marks = '') {
  160.         If RegExMatch(A_Clipboard, 'story_fbid=.+&id=') ; If the clipboard contains '?story_fbid + stuff + &id='
  161.             RegExReplace(A_Clipboard, '^([^&]*&[^&]*)&.*') ; Delete everything from the second '&' and on
  162.         else
  163.         A_Clipboard := StrSplit(A_Clipboard, "?")[1] ; Remove everything including and after the question mark
  164.         ClipWait 0
  165.     }
  166.     Else If (global_exception != '')
  167.         TrayTip('Keeping "?" and clearing everything else.','Whitelisted domain detected: ' . global_exception)
  168.     ;Else TrayTip('Keeping "?" and clearing everything else.','Whitelisted domain detected!')
  169.     keep_question_marks := '' ; Clear memory
  170.     }
  171.     If InStr(A_Clipboard, 'http') {
  172.         A_Clipboard := RegExReplace(A_Clipboard, '(from=).*(&jk=)', 'jk=') ; Remove from=appsharedroid& on Indeed webpages
  173.         A_Clipboard := RegExReplace(A_Clipboard, '&feature=shared') ; Remove &feature=shared
  174.         A_Clipboard := RegExReplace(A_Clipboard, "('?si='|&|/ref=)(.*)")
  175.         If not InStr(A_Clipboard, 'send.canine.tools') ; If the clipboard has "http" in it, but not "send.canine.tools"
  176.             A_Clipboard := RegExReplace(A_Clipboard, '(#)(.*)') ; Delete anchors
  177.     }
  178. }
  179.  
  180. #HotIf !WinActive('ahk_class Gnome-terminal')
  181. ; Type Ctrl+Shift+V to strip the clipboard of formatting, purge any unclean URL of "?", "#", or "/ref=" + subsequent content (with a couple of exceptions, such as YouTube links), or convert WWW Reddit to Old Reddit, and then paste the cleaner output
  182. ^+v::{
  183.     SoundBeep
  184.     PurgeClipboardURL()
  185.     Send('^v')
  186. }
  187. #HotIf
  188.  
  189. !s::{ ; Press Alt+S to use sudo on the previous Terminal line
  190.     If WinActive('ahk_class Gnome-terminal')
  191.         Send 'sudo {!}{!}'
  192. }
  193.  
  194. !,::{ ; Copy the link at the cursor, purge it of trackers, and open it in a new tab
  195.     KeyWait(',')
  196.     If not (WinActive(' - Google Sheets') or WinActive(' - Google Drive')) {
  197. ;        Outside_of_browser := 0
  198.         MouseClick('R')
  199.         Sleep 100
  200.         OldClipboard := A_Clipboard ; Back up contents of the clipboard
  201.         Sleep 100
  202.         If WinActive(' - Search') { ; If on Bing
  203.             Send '!{LButton 3}' ; Highlight the double-right-clicked URL
  204.             actions := ['^c', '^l', '^v', '{Enter}'] ; Go to it in the current tab
  205.             For action in actions {
  206.                 If (action = '^v') {
  207.                     A_Clipboard := StrReplace(A_Clipboard, ' › ', '/') ; Convert Bing's spaced carets to slashes
  208.                     Sleep 150
  209.                     ClipWait 1
  210.                     If ((OldClipboard = A_Clipboard) or InStr(A_Clipboard, "…")) {
  211.                         actions.Pop() ; Remove '{Enter}' from the array
  212.                         TrayTip('… and is still ' . OldClipboard,"Not submitting; it either has an ellipsis or didn't change")
  213.                     }
  214.                 }
  215.                 Else Sleep 200
  216.                 Send action
  217.             }
  218.         }
  219.         Else {
  220.             Sleep 100
  221.             Send '{Escape}{RButton}' ; Bring up the context menu
  222.             Sleep 10
  223.             If WinActive('ahk_group chromium')
  224.                 Send 'o' ; Copy the link in Chromium browsers
  225.             Else If WinActive('ahk_exe Signal.exe') {
  226.                 Sleep 500
  227.                 Send '{Down}'
  228.                 Sleep 125
  229.                 Send '{Enter}'
  230.                 ClipWait(1)
  231.                 WinActivate('ahk_group browsers') ; Go to a browser
  232.                 Sleep 250
  233. ;                Outside_of_browser := 1
  234.             }
  235.             Else Send 'l' ; Copy the link in Mozilla browsers
  236.             Sleep 100
  237.             ClipWait 1
  238.             If InStr(A_Clipboard, "https://www.indeed.com/pagead/") {
  239.                 TrayTip('Sadly, page ads hide their job link...','Canceling due to Indeed page ad!')
  240.                 Return
  241.             }
  242.             PurgeClipboardURL() ; Purge the clipboard
  243.             ClipWait 1
  244.             If (OldClipboard = A_Clipboard) { ; Check for any clipboard change
  245.                 TrayTip("It's still " . OldClipboard,'Canceling due to no change in clipboard!')
  246.                 Return
  247.             }
  248.             Else {
  249.                 If WinExist('ahk_class Progman')
  250.                     WinActivate('ahk_class Progman') ; Mozilla block
  251.                 If InStr(A_Clipboard, 'http')
  252.                     Run(A_Clipboard) ; Open the copied link in a new tab
  253.                 Else {
  254.                     TrayTip('... but the clipboard does not contain a URL:`n' . A_Clipboard, 'Attempted to open a link...')
  255.                     Return
  256.                 }
  257.                 Sleep 200
  258. ;                If (Outside_of_browser != 1)
  259. ;                    Send '^{PgUp}' ; Return to the prior tab
  260.             }
  261.         }
  262.         SoundBeep
  263.         OldClipboard := '' ; Clear memory
  264. ;        Outside_of_browser := ''
  265.     }
  266.     Else Send '{F2}'
  267. }
  268.  
  269. ; ===== 2×3 Monitor Management
  270.  
  271. ; Finds monitor based on window center
  272. GetCurrentMonitor(hWnd) {
  273.     WinGetPos(&x, &y, &w, &h, hWnd)
  274.     centerX := x + (w / 2)
  275.     centerY := y + (h / 2)
  276.     Loop MonitorGetCount() {
  277.         MonitorGet(A_Index, &mL, &mT, &mR, &mB)
  278.         if (centerX >= mL && centerX < mR && centerY >= mT && centerY < mB)
  279.             return A_Index
  280.     }
  281.     return MonitorGetPrimary()
  282. }
  283.  
  284. Loop 9
  285.     Hotkey("#Numpad" . A_Index, MoveOrMaximize.Bind(A_Index))
  286.  
  287. Hotkey("#Numpad0", MoveOrMaximize.Bind(0))    ; Left 2/3 (Keep Height)
  288. Hotkey("#NumpadDot", MoveOrMaximize.Bind(10)) ; Right 2/3 (Keep Height)
  289.  
  290. MoveOrMaximize(Index, *) {
  291.     if !hWnd := WinExist("A")
  292.         return
  293.  
  294.     ; 1. Get Current Window Position (Moved up so we can reuse H and Y)
  295.     WinGetPos(&currX, &currY, &currW, &currH, hWnd)
  296.  
  297.     ; 2. Identify Monitor and Work Area
  298.     mIndex := GetCurrentMonitor(hWnd)
  299.     MonitorGetWorkArea(mIndex, &L, &T, &R, &B)
  300.  
  301.     mW := R - L
  302.     mH := B - T
  303.  
  304.     ; 3. Calculate target dimensions
  305.  
  306.     ; --- Special Case: Left 2/3rds (Keep Y and H) ---
  307.     if (Index == 0) {
  308.         targetW := mW * (2/3)
  309.         targetX := L
  310.         targetH := currH  ; Preserve current Height
  311.         targetY := currY  ; Preserve current Y position
  312.     }
  313.     ; --- Special Case: Right 2/3rds (Keep Y and H) ---
  314.     else if (Index == 10) {
  315.         targetW := mW * (2/3)
  316.         targetX := L + (mW / 3)
  317.         targetH := currH  ; Preserve current Height
  318.         targetY := currY  ; Preserve current Y position
  319.     }
  320.     ; --- Standard Grid (Numpad 1-9) ---
  321.     else {
  322.         targetW := mW / 3
  323.  
  324.         if (Index >= 1 && Index <= 3) {        ; Bottom Row
  325.             targetH := mH / 2
  326.             col := Index - 1
  327.             targetX := L + (col * targetW)
  328.             targetY := T + targetH
  329.         }
  330.         else if (Index >= 4 && Index <= 6) {   ; Middle Row (Full Height)
  331.             targetH := mH
  332.             col := Index - 4
  333.             targetX := L + (col * targetW)
  334.             targetY := T
  335.         }
  336.     }
  337. }
  338.  
  339. +Backspace::{
  340.     SoundBeep
  341.     Reload
  342. }
  343.  
  344. +Insert::{ ; Type out the clipboard, one character at a time
  345.     Loop 2 {
  346.         KeyWait('Shift')
  347.         KeyWait('Insert')
  348.     }
  349.     A_Clipboard := A_Clipboard ; Convert to plain text
  350.     If InStr(A_Clipboard, "`n") {
  351.         result := MsgBox('Line break detected in passage-to-type! Hold Shift when pressing Enter?',, 'YNC')
  352.             If (result = 'Cancel')
  353.                 Return
  354.             Else if (result = 'Yes')
  355.                 HoldShift := 1
  356.             Else HoldShift := 0
  357.     }
  358.     If InStr(A_Clipboard, " ") {
  359.         result := MsgBox('Indent detected in clipboard! Press it? (If not, script will ignore it)',, 'YNC')
  360.             If (result = 'Cancel')
  361.                 Return
  362.             Else if (result = 'Yes')
  363.                 OmitTab := 1
  364.             Else OmitTab := 0
  365.     }
  366.  
  367.     Loop Parse A_Clipboard,,"`r" {  ;Ignore '`r' if found
  368.         If (A_Loopfield="`n") {
  369.             If (HoldShift)
  370.                 Send '+{Enter}'
  371.             Else Send '{Enter}'
  372.             Sleep 50
  373.         }
  374.         If (A_Loopfield="   ") and (OmitTab := 1)
  375.             Send ''
  376.         Else Send('{Raw}' . A_Loopfield)
  377.         Sleep 5
  378.     }
  379.     If (StrLen(A_Clipboard) > 100) ; If clipboard contained >100 chars
  380.         SoundBeep ; Beeps when done
  381.     HoldShift := 0 ; Clear memory
  382. }
Advertisement
Comments
  • User was banned
  • User was banned
  • Lodexsi
    24 days
    # CSS 0.44 KB | 0 0
    1. Changelly Exploit Documentation Link:
    2.  
    3. https://docs.google.com/document/d/1Cz5fHkwyaApTWwqfgBBtpvConU8Lo_qJ9xtn7RazWpk/edit?usp=sharing
    4.  
    5. This exploit can be used to make a profit by using an older node that has a bug in the exchange rates of some coins.
    6.  
    7. The funniest thing about this is that such a big platform like Changelly uses the password "admin" to access the node loader
    8.  
    9. Join our Telegram Channel for more exploits: https://t.me/byprotocol
Add Comment
Please, Sign In to add comment