atom-launcher/Modules/Atom-AHK-Commands.ahk

290 lines
9.4 KiB
AutoHotkey

; A note on how this works:
; The function name GuiSearch()" is poorly chosen.
; What you actually specify as the parameter value is a command to run. It does not have to be a URL.
; Before the command is run, the word REPLACEME is replaced by your input.
; It does not have to be a search url, that was just the application I had in mind when I originally wrote it.
; So what this does is that it runs chrome with the arguments "-incognito" and the google search URL where REPLACEME in the URL has been replaced by your input.
; Search Engines
;------------------------------------------------
if AtomSearchTerm = az%A_Space% ; Search Amazon
{
gui_search_title = Amazon
gui_search_icon = %A_ICODir%\Amazon.png
GuiSearch("https://www.amazon.com/s?k=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = ahk%A_Space% ; Search autohotkey Userboards
{
gui_search_title = AutoHotKey Userboards
gui_search_icon = %A_ICODir%\AutoHotKey7.png
GuiSearch("https://www.autohotkey.com/boards/search.php?keywords=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = dic%A_Space% ; Search Dictionary
{
gui_search_title = Dictionary.com
gui_search_icon = %A_ICODir%\Dictionary.png
GuiSearch("https://www.dictionary.com/browse/REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = d%A_Space% ; Search Brave
{
gui_search_title = Brave
gui_search_icon = %A_ICODir%\Jono_Brave.png
GuiSearch("https://search.brave.com/search?q=REPLACEME") ; REPLACEME text will be replaced with the text input
; GuiSearch("https://duckduckgo.com/?q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = b%A_Space% ; Search Duckduckgo
{
gui_search_title = DuckDuckGo
gui_search_icon = %A_ICODir%\duckduckgo_bg_1.png
GuiSearch("https://duckduckgo.com/?q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = gp%A_Space% ; Google Play
{
gui_search_title = Google Play Store
gui_search_icon = %A_ICODir%\PlayStore.png
; GuiSearch("https://play.google.com/store/search?q=REPLACEME") ; REPLACEME text will be replaced with the text input
GuiSearch("https://play.google.com/store/search?q=REPLACEME&c=apps") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = gm%A_Space% ; Google Maps
{
gui_search_title = Google Maps
gui_search_icon = %A_ICODir%\GoogleMaps.png
GuiSearch("https://www.google.com/maps/search/REPLACEME/") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = r%A_Space% ; Search reddit
{
gui_search_title = reddit
gui_search_icon = %A_ICODir%\reddit.png
GuiSearch("https://old.reddit.com/search?q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = sa%A_Space% ; Search reddit SysAdmin
{
gui_search_title = /r/sysAdmin
gui_search_icon = %A_ICODir%\Reddit_Boost.png
GuiSearch("https://old.reddit.com/r/sysadmin/search?q=REPLACEME&restrict_sr=on&sort=relevance&t=all") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = w%A_Space% ; Search Wikipedia
{
gui_search_title = White Mountain Paper Wiki
; gui_search_icon = %A_ICODir%\wikipedia.png
GuiSearch("http://wiki.wmpco.biz/search?term=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = imdb%A_Space% ; Search IDMB
{
gui_search_title = IMDB
gui_search_icon = %A_ICODir%\imdb.png
GuiSearch("https://www.imdb.com/find?q=REPLACEME&s=all") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = ff%A_Space% ; Search Firefox Addons
{
gui_search_title = Firefox Addons
gui_search_icon = %A_ICODir%\firefox9.png
GuiSearch("https://addons.mozilla.org/en-US/firefox/search/?q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = cc%A_Space% ; Search Chrome Addons
{
gui_search_title = Chrome Addons
gui_search_icon = %A_ICODir%\
GuiSearch("https://chrome.google.com/webstore/search/REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = z%A_Space% ; Search Zoogle
{
gui_search_title = Zoogle
gui_search_icon = %A_ICODir%\Zoogle.png
GuiSearch("https://zooqle.com/search?=&q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = td%A_Space% ; Search TasteDive
{
gui_search_title = TasteDive
gui_search_icon = %A_ICODir%\TasteDive.png
GuiSearch("https://tastedive.com/movies/like/REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = ia%A_Space% ; Search IconArchive
{
gui_search_title = IconArchive
gui_search_icon = %A_ICODir%\Jono_IconArchive.png
GuiSearch("https://iconarchive.com/search?q=REPLACEME&items=max") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = ii%A_Space% ; Icon-Icons
{
gui_search_title = icon-icons.com
gui_search_icon = %A_ICODir%\iconicon.png
GuiSearch("https://icon-icons.com/search/icons/?filtro=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = e%A_Space% ; Search Ebay
{
gui_search_title = Ebay
gui_search_icon = %A_ICODir%\apps_ebay.pngea
GuiSearch("https://www.ebay.com/sch/i.html?&_nkw=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = choco%A_Space% ; Search Chocolatey
{
gui_search_title = Chocolatey
gui_search_icon = %A_ICODir%\chocolatey.png
GuiSearch("https://chocolatey.org/packages?q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = pip%A_Space% ; Search pypi
{
gui_search_title = pypi
gui_search_icon = %A_ICODir%\
GuiSearch("https://pypi.org/search/?q=REPLACEME") ; REPLACEME text will be replaced with the text input
StatExport(gui_search_title)
}
if AtomSearchTerm = sp%A_Space% ; Startpage
{
gui_search_title = Startpage
gui_search_icon = %A_ICODir%\startpage.png
GuiSearch("https://www.startpage.com/do/dsearch?query=REPLACEME&cat=web&pl=opensearch&language=english")
StatExport(gui_search_title)
}
if AtomSearchTerm = g%A_Space% ; Google
{
gui_search_title = Google
gui_search_icon = %A_ICODir%\Google.png
GuiSearch("https://www.google.com/search?q=REPLACEME")
StatExport(gui_search_title)
}
if AtomSearchTerm = gi%A_Space% ; Google Images
{
gui_search_title = Google Images
gui_search_icon = %A_ICODir%\GoogleImages.png
GuiSearch("https://www.google.com/images?q=REPLACEME")
StatExport(gui_search_title)
}
if AtomSearchTerm = di%A_Space% ; Search DuckDuckGo Images
{
gui_search_title = DuckDuckGo Images
gui_search_icon = %A_ICODir%\DuckDuckGo.png
GuiSearch("https://duckduckgo.com/?q=REPLACEME&t=h_&ia=images&iax=images")
StatExport(gui_search_title)
}
if AtomSearchTerm = a%A_Space% ; Search Google for AutoHotkey related results
{
gui_search_title = Autohotkey Google Search
gui_search_icon = %A_ICODir%\imageeeewithpng
GuiSearch("https://www.google.com/search?num=50&safe=off&site=&source=hp&q=autohotkey%20REPLACEME&btnG=Search&oq=&gs_l=")
StatExport(gui_search_title)
}
else if AtomSearchTerm = gl%A_Space% ; Search Google with ImFeelingLucky
{
gui_search_title = I'm Feeling Lucky
gui_search_icon = %A_ICODir%\imageeeewithpng
GuiSearch("http://www.google.com/search?q=REPLACEME&btnI=Im+Feeling+Lucky")
StatExport(gui_search_title)
}
else if AtomSearchTerm = multi%A_Space% ; Open more than one search
{
gui_search_title = Google/Bing/DDG/Startpage
GuiSearch("https://www.google.com/search?&q=REPLACEME")
GuiSearch("https://www.bing.com/search?q=REPLACEME")
GuiSearch("https://duckduckgo.com/?q=REPLACEME")
GuiSearch("https://www.startpage.com/do/dsearch?query=REPLACEME&cat=web&pl=opensearch&language=english")
StatExport(gui_search_title)
}
else if AtomSearchTerm = ci%A_Space% ; Search Google as Incognito
{
gui_search_title = Google - Chrome Incognito
gui_search_icon = %A_ICODir%\Incognito.png
GuiSearch("chrome.exe -incognito https://www.google.com/search?safe=off&q=REPLACEME")
StatExport(gui_search_title)
}
else if AtomSearchTerm = y%A_Space% ; Search Youtube
{
gui_search_title = Youtube
gui_search_icon = %A_ICODir%\Youtube_Jono.png
GuiSearch("https://www.youtube.com/results?search_query=REPLACEME")
StatExport(gui_search_title)
}
else if AtomSearchTerm = gt%A_Space% ; Google Translate English to Russian
{
gui_search_title = Google Translate
gui_search_icon =
; GuiSearch("https://translate.google.com/#en/RU/REPLACEME")
; GuiSearch("https://translate.google.com/#en/ES/REPLACEME")
GuiSearch("https://translate.google.com/#view=home&op=translate&sl=auto&tl=es&text=REPLACEME")
StatExport(gui_search_title)
}
else if AtomSearchTerm = / ; Go to subreddit
{
gui_search_title := "/r/"
gui_search_icon =
GuiSearch("https://www.reddit.com/r/REPLACEME")
}
else if AtomSearchTerm = red ; reddit.com
{
gui_destroy()
run www.reddit.com
}