here is an example that will activate firefox/seamonkey and paste the clipboard contents into the url bar:
Code: Select all
#!/bin/sh
xdotool search --classname Navigator \
windowactivate --sync key --delay 250 ctrl+t ctrl+k ctrl+v Return
Code: Select all
#!/bin/sh
xdotool search --classname Navigator \
windowactivate --sync key --delay 250 ctrl+t ctrl+k ctrl+v Return
Code: Select all
xdotool search --name "VLC" behave %@ mouse-click exec 'myscript'
Code: Select all
#! /bin/sh
# ht_b
# miriam 2012-09-06
# adds bold tags around a selection of text in any text editor
xclip -o | sed 's/^/<b>/' | sed 's/$/<\/b>/' | xclip -selection clipboard
xdotool type "`xclip -out -selection clipboard`"
miriam.miriam wrote:
I've made a number of other small scripts to do the same for other tags (italic, headlines 1/2/3, and blockquote) and I've put their icons on the desktop too. Clicking on them is a lot easier than hand-editing editing arbitrary text. (It would be even easier if I could get keyboard shortcuts to work properly too instead of having to mouse-click on an icon, but I can't stop the keyboard shortcuts from producing multiple events.)
Another itch scratched.
Code: Select all
#!/bin/sh
# substitute a selection with <tag>selection</tag>
# assign script to hotkey
SEL=`Xdialog --no-tags --stdout --title "List of Tags" \
--menu "Please Choose a Tag:" 20 51 4 \
"b" "Bold" \
"i" "Italic" \
"h2" "Large Heading" \
"p" "Paragraph" \
"hr" "Horizontal Rule" \
"br" "Line Break"`
xclip -o | sed 's/^/<'"$SEL"'>/' | sed 's/$/<\/'"$SEL"'>/' | xclip -selection clipboard
xdotool key ctrl+v
yeah sc0ttman, good idea!sc0ttman wrote:Fancy hacking the source to get the following command working?
Code: Select all
xdotool search --name "VLC" behave %@ mouse-click exec 'myscript'
scOttman,sc0ttman wrote:yeah sc0ttman, good idea!sc0ttman wrote:Fancy hacking the source to get the following command working?
Code: Select all
xdotool search --name "VLC" behave %@ mouse-click exec 'myscript'
Code: Select all
xdotool search --name "VLC" behave %@ focus exec echo Yes
Code: Select all
while :; do xdotool mousemove_relative -- -$(($RANDOM % 10)) $(($RANDOM % 10)); xdotool mousemove_relative -- $(($RANDOM % 10)) -$(($RANDOM % 10)); done
People with Parkinson's won't think it's funny !!!technosaurus wrote:annoying mouse funCode: Select all
while :; do xdotool mousemove_relative -- -$(($RANDOM % 10)) $(($RANDOM % 10)); xdotool mousemove_relative -- $(($RANDOM % 10)) -$(($RANDOM % 10)); done
Code: Select all
echo $PATH
Code: Select all
PATH=$PATH:/the/new/dir/of/programs
This is like buying a beautiful car, only to realise the engine is made of cake and rotting brocolli. ..Mac OS X is especially egregious in this regard - open a terminal and check the directory listing at root - it's an even bigger mess than regular UNIX.
Code: Select all
find ./ -iname "*txt"