diff options
| -rwxr-xr-x | launch/dmenu_runapp | 5 | ||||
| -rwxr-xr-x | launch/virt | 6 | ||||
| -rwxr-xr-x | misc/mime | 9 | ||||
| -rwxr-xr-x | video/ffconcat | 17 | ||||
| -rwxr-xr-x | video/ytdl-dlplst | 5 | ||||
| -rwxr-xr-x | x11/testtimmywm | 6 | ||||
| -rwxr-xr-x | x11/xvsync | 5 | 
7 files changed, 37 insertions, 16 deletions
diff --git a/launch/dmenu_runapp b/launch/dmenu_runapp new file mode 100755 index 0000000..2de77f4 --- /dev/null +++ b/launch/dmenu_runapp @@ -0,0 +1,5 @@ +#!/bin/sh +apps=/usr/share/applications +name="$(grep -h -m1 '^Name=' $apps/* | cut -d'=' -f2- | sort | uniq | dmenu "$@")" +#$(grep '^Exec=[^%]*' -o -m1 $(grep -l -m1 "$name" $apps/*) | cut -d'=' -f2-) & +gtk-launch $(basename `grep -l -m1 "$name" $apps/*` .desktop) & diff --git a/launch/virt b/launch/virt index f1035a0..9706106 100755 --- a/launch/virt +++ b/launch/virt @@ -10,15 +10,15 @@ startvm() {  		-m $(halfram) \  		-smp $(halfthreads) \  		-net nic \ -		-nographic \ -		-vga none \ +		-display sdl,gl=on \  		-audiodev pa,id=pa1,server=/run/user/1000/pulse/native \  		-soundhw all \  		-boot menu=on \  		-drive file="$virtdir/$1.img" \  ; } +		#-vga none \ +		#-nographic \ -		#-display sdl,gl=on \  vms="$(ls $virtdir)"  [ -n "$1" ] && vm="$1" || vm=$(echo "$vms" | sed 's/\.img//' | dmenu -p "Choose Virtual Machine Image or Enter Name for New Virtual Machine") @@ -65,6 +65,7 @@ echo  # Choose subtype  mtypefile="$cachedir/$mtype.csv"  [ -e "$mtypefile" ] && interactiveopt "all\n$(cut -d',' -f1 "$mtypefile" | tail -n +2)" "Choose $mtype subtype: " "" col +mfiletypes=" $opt "  echo  # Choose program @@ -73,8 +74,12 @@ program="$opt"  echo "$program"  echo +#echo "$mfiletypes" | grep ' all ' && mfiletypes="$(cut -d',' -f1 "$cachedir/$mtype.csv" | tail -n +2)" +  # Xdg-mime commands -#echo "All $mtype Types\n$(cut -d',' -f1 "$cachedir/image.csv" | tail -n +2)"  #cut -d',' -f2 "$cachedir/image.csv" -#[ -n "$mimetype" ] && xdg-mime default $application.desktop $mimetype +for mfiletype in $(cut -d',' -f1 "$cachedir/$mtype.csv" | tail -n +2); do +	echo "Changing default program for $mfiletype to $program" +	xdg-mime default "$program.desktop" $mfiletype +done diff --git a/video/ffconcat b/video/ffconcat index 7e903f6..06eb066 100755 --- a/video/ffconcat +++ b/video/ffconcat @@ -1,17 +1,12 @@  #!/bin/sh -#for out; do true; done # get last argument -filelist=$(mktemp ${TMPDIR:-/tmp}/ffconcat.XXXXXX) || exit -pwd="$(pwd)" -for out; do -	[ -e "$pwd/$out" ] \ -	&& files="$pwd/$out\n$files" \ -	|| ([ -e "$out" ] && files="$out\n$files") -done -echo $files | tail +2 | sed -n "s/\(.\+\)/file '\1'/p"# > $filelist +ffconcat="$(ls | sed "s/^/file '/; s/$/'/")" +echo "$ffconcat" > ffconcat  ffmpeg \  	-f concat \  	-safe 0 \ -	-i $filelist \ +	-i ffconcat \  	-c copy \ -	$out +	out.mkv + +rm ffconcat diff --git a/video/ytdl-dlplst b/video/ytdl-dlplst new file mode 100755 index 0000000..f7b4a47 --- /dev/null +++ b/video/ytdl-dlplst @@ -0,0 +1,5 @@ +#!/bin/sh +echo "Getting Video ID's..." +for id in $(youtube-dl --get-id "$1"); do +	youtube-dl --newline "https://youtu.be/$id" & +done diff --git a/x11/testtimmywm b/x11/testtimmywm new file mode 100755 index 0000000..330a328 --- /dev/null +++ b/x11/testtimmywm @@ -0,0 +1,6 @@ +#!/bin/sh + +Xephyr -br -ac -reset -screen 2160x1440 :1 & +sleep 1 +export DISPLAY=:1 +timmywm & diff --git a/x11/xvsync b/x11/xvsync new file mode 100755 index 0000000..0d5cd5c --- /dev/null +++ b/x11/xvsync @@ -0,0 +1,5 @@ +#!/bin/sh +# Since this script runs xrandr to get the connected monitors, it is unnecessary to run xrandr by itself in your xinitrc +for monitor in `xrandr | sed -n 's/ connected.*//p'`; do +	xrandr --output $monitor --set TearFree ${1:-on} +done  | 
