Skip to content

Instantly share code, notes, and snippets.

@davebrny
davebrny / python_termux.tsk.xml
Created Jun 13, 2022
(tasker) a task that runs the termux plugin and termux-relay.py
View python_termux.tsk.xml
<TaskerData sr="" dvi="1" tv="5.15.14">
<Task sr="task775">
<cdate>1653984629316</cdate>
<edate>1655136097308</edate>
<id>775</id>
<nme>python termux &gt;</nme>
<pri>100</pri>
<Action sr="act0" ve="7">
<code>547</code>
<label>set par1</label>
@davebrny
davebrny / termux-relay.py
Created Jun 13, 2022
(python, termux) run python scripts outside of the .termux/tasker folder
View termux-relay.py
#!/data/data/com.termux/files/usr/bin/python
import sys
import subprocess
file = sys.argv[1]
args = ' '.join(map(str, sys.argv[2:]))
subprocess.run(['python', file, args])
@davebrny
davebrny / button-bixby-double.prf.xml
Created Dec 20, 2020
(tasker) bixby button remapping
View button-bixby-double.prf.xml
<TaskerData sr="" dvi="1" tv="5.10.1">
<Profile sr="prof550" ve="2">
<cdate>1576780136016</cdate>
<cldm>3</cldm>
<clp>true</clp>
<edate>1608422876984</edate>
<flags>8</flags>
<id>550</id>
<mid0>545</mid0>
<nme>button - bixby double</nme>
@davebrny
davebrny / text launcher.ahk
Last active Mar 14, 2022
(autohotkey) - launch files/folders/urls from a text list
View text launcher.ahk
#noEnv
#singleInstance, force
sendMode, input
return
!l:: goSub, get_text_to_launch
!+l::goSub, text_launcher ; repeat last selection
@davebrny
davebrny / orbv.ahk
Created Jul 5, 2019
(autohotkey) - one-liners to restore built-in variables
View orbv.ahk
^!b::
if (orb_list = "")
{
orb_list =
(lTrim
autoTrim | autoTrim | "off"
batchLines | setBatchLines | -1
controlDelay | setControlDelay | -1
coordModeCaret | coordMode, caret | "client"
coordModeMenu | coordMode, mouse | "client"
@davebrny
davebrny / run in Wine.py
Last active Jun 27, 2019
(autokey) - select a file to run in Wine
View run in Wine.py
import getpass
import os.path
import subprocess
keyboard.send_keys("<ctrl>+c")
time.sleep(0.2)
str = clipboard.get_clipboard()
if "/.wine/" not in str: # if path is a native linux folder
user = getpass.getuser()
@davebrny
davebrny / txt.wrap.ahk
Last active Jul 10, 2022
✏️ (autohotkey) - wrap selected text in *symbols*
View txt.wrap.ahk
/*
[wrap list]
( = (TXT)
`[ = [TXT]
{ = {TXT}
< = <TXT>
> = >TXT<
a = /`*TXT*`/
h = <!-- TXT -->
@davebrny
davebrny / i.mage.ahk
Last active Jan 17, 2022
🧙‍♂️ (autohotkey) - one click image download
View i.mage.ahk
/*
[hotkeys]
!p = C:\Users\%a_userName%\Pictures\.i.mages
[browser]
ahk_exe chrome.exe
ahk_exe firefox.exe
ahk_exe iexplore.exe
ahk_exe vivaldi.exe
@davebrny
davebrny / close_maps_gps_dialog.prf.xml
Last active Jun 13, 2019
(tasker) close annoying "no gps" message in maps.me on android
View close_maps_gps_dialog.prf.xml
<TaskerData sr="" dvi="1" tv="5.7.1">
<Profile sr="prof578" ve="2">
<cdate>1327589128179</cdate>
<edate>1559496172752</edate>
<flags>16</flags>
<id>578</id>
<mid0>586</mid0>
<nme>close maps gps dialog</nme>
<Event sr="con0" ve="2">
<code>1610740602</code>
@davebrny
davebrny / txt.replace.ahk
Last active Jun 17, 2019
(autohotkey) - replace a character with another, interactively
View txt.replace.ahk
#noEnv
#singleInstance, force
sendMode input
return ; end of auto-execute ---------------------------------------------------
!r:: goSub, txt_replace
!+r::goSub, use_last_replace