removed some more generated files
This commit is contained in:
parent
0b36f32d62
commit
1de67c6710
@ -1,3 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
rofi -dmenu -font 'DejaVu Sans 10' -password -no-fixed-num-lines \
|
|
||||||
-p (printf $argv[1] | sed s/://)
|
|
@ -1,7 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
set SELECTEDWIFI (nmcli d w l | egrep -o '([0-9A-F]{2}:){5}[0-9A-F]{2}\s*(.*)Infra' | egrep -o '\s+(.*)\s+' | awk '{$1=$1}1' | rofi -dmenu -p "Select your WiFi network")
|
|
||||||
|
|
||||||
if test -z $SELECTEDWIFI
|
|
||||||
notify-send "No WiFi network selected" -u low && exit
|
|
||||||
end
|
|
||||||
nmcli c u $SELECTEDWIFI
|
|
@ -1,2 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
/usr/bin/dart $DART_SDK/snapshots/analysis_server.dart.snapshot --lsp
|
|
@ -1,2 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
rofi -dmenu $argv
|
|
@ -1,5 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
devID=$( xinput list | grep "TouchPad" | sed -n -e 's/.*id=\([0-9]*\).*/\1/p' )
|
|
||||||
propID=$( xinput list-props $devID | grep "Tapping Enabled (" | sed -n -e 's/.*(\([0-9]*\)).*/\1/p' )
|
|
||||||
xinput set-prop $devID $propID 1
|
|
@ -1,2 +0,0 @@
|
|||||||
#!/usr/bin/fish
|
|
||||||
ls -ahlX --group-directories-first $argv | bat
|
|
@ -1,17 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
killall -q polybar
|
|
||||||
|
|
||||||
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
|
|
||||||
|
|
||||||
if type "xrandr"; then
|
|
||||||
for m in $(xrandr --query | grep " connected" | cut -d" " -f1); do
|
|
||||||
MONITOR=$m polybar --reload top &
|
|
||||||
MONITOR=$m polybar --reload bottom &
|
|
||||||
done
|
|
||||||
else
|
|
||||||
polybar --reload top &
|
|
||||||
polybar --reload bottom &
|
|
||||||
fi
|
|
||||||
|
|
||||||
notify-send "Polybar restarted!" -a "polybar-launch"
|
|
@ -1,7 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
grep -v "#" ~/.config/emoji.txt | rofi -dmenu -p "Select emoji" -i | awk '{print $1}' | tr -d '\n' | xclip -selection clipboard
|
|
||||||
|
|
||||||
set emoji (xclip -o -selection clipboard | tr -d '\n')
|
|
||||||
test -z "$emoji" && notify-send "No emoji copied" -u low && exit
|
|
||||||
set -a emoji "copied to clipboard"
|
|
||||||
pgrep -x dunst >/dev/null && notify-send -u low $emoji
|
|
@ -1,146 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
|
|
||||||
begin
|
|
||||||
|
|
||||||
set -l LFS
|
|
||||||
|
|
||||||
set -l a (math (jmtpfs -l | wc -l) - 2)
|
|
||||||
test $a -ge 0 && jmtpfs -l 2> /dev/null | tail -n $a | read -zg anddrives
|
|
||||||
|
|
||||||
lsblk -rpo "name,type,size,mountpoint" | \
|
|
||||||
awk '$2=="part"&&$4==""{printf "%s (%s)\n",$1,$3}' | \
|
|
||||||
read -zg usbdrives
|
|
||||||
|
|
||||||
blkid /dev/sr0 | awk '{print $1}' | sed 's/://' | read -z cddrives
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
set -g TMPDRIVES /tmp/drives
|
|
||||||
rm -f $TMPDRIVES
|
|
||||||
touch $TMPDRIVES
|
|
||||||
|
|
||||||
test -n "$usbdrives" && echo "USB" >> $TMPDRIVES
|
|
||||||
test -n "$cddrives" && echo "CD" >> $TMPDRIVES
|
|
||||||
test -n "$anddrives" && echo "Android" >> $TMPDRIVES
|
|
||||||
|
|
||||||
set -g basemount /media
|
|
||||||
|
|
||||||
function getmount
|
|
||||||
|
|
||||||
set -g mp (for d in $basemount
|
|
||||||
find $d -maxdepth 5 -type d
|
|
||||||
end | rofi -dmenu -i -p 'Type in mount point.')
|
|
||||||
|
|
||||||
if test -z $mp || test $mp = ""
|
|
||||||
return 1
|
|
||||||
end
|
|
||||||
|
|
||||||
if test ! -d $mp
|
|
||||||
switch (printf "No\\nYes" | rofi -dmenu -i -p "$mp does not exist. Create it?")
|
|
||||||
case 'Yes'
|
|
||||||
mkdir -p $mp || sudo -A mkdir -p $mp
|
|
||||||
case '*'
|
|
||||||
return 1
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function mountusb
|
|
||||||
|
|
||||||
set -g chosen (echo $usbdrives | \
|
|
||||||
rofi -dmenu -i -p "Mount which drive?" | \
|
|
||||||
awk '{print $1}')
|
|
||||||
|
|
||||||
test -z $chosen && return 1
|
|
||||||
|
|
||||||
getmount
|
|
||||||
|
|
||||||
test -z $mp && return 1
|
|
||||||
|
|
||||||
switch (lsblk -no "fstype" $chosen)
|
|
||||||
|
|
||||||
case "vfat"
|
|
||||||
sudo -A mount -t vfat $chosen $mp -o rw,umask=0000
|
|
||||||
|
|
||||||
case "ntfs"
|
|
||||||
sudo -A mount -t ntfs $chosen $mp -o rw,umask=0000
|
|
||||||
|
|
||||||
case '*'
|
|
||||||
sudo -A mount $chosen $mp
|
|
||||||
|
|
||||||
sudo -A chown -R $USER:(id -g $USER) $mp
|
|
||||||
|
|
||||||
end && notify-send -a "dmount" "💻 USB mounting" "$chosen mounted to $mp."
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function mountandroid -d "Mount an Android device"
|
|
||||||
|
|
||||||
set chosen (echo $anddrives | rofi -dmenu -i -p "Which Android device?" | awk '{print $1 $2}' | sed 's/,$//')
|
|
||||||
|
|
||||||
set bus (echo $chosen | sed 's/,.*//')
|
|
||||||
|
|
||||||
jmtpfs -device=$chosen $mp
|
|
||||||
|
|
||||||
echo "OK" | \
|
|
||||||
rofi -dmenu -i -p "Press (Allow) on your phone screen, or set your USB settings to allow file transfert"
|
|
||||||
|
|
||||||
set newchosen (jmtpfs -l | grep $bus | awk '{print $1 $2}' | sed 's/,$//')
|
|
||||||
sudo -A umount $mp
|
|
||||||
|
|
||||||
jmtpfs -device=$newchosen $mp && \
|
|
||||||
notify-send -a "dmount" "🤖 Android Mounting" "Android device mounted to $mp."
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function mountcd
|
|
||||||
|
|
||||||
set chosen (echo $cddrives | rofi -dmenu -i -p "Which CD drive?")
|
|
||||||
|
|
||||||
getmount
|
|
||||||
|
|
||||||
sudo -A mount $chosen $mp && \
|
|
||||||
notify-send -a "dmount" "💿 CD mounting" "$chosen mounted."
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function asktype
|
|
||||||
|
|
||||||
switch (cat $TMPDRIVES | rofi -dmenu -i -p "Mount which drive?")
|
|
||||||
|
|
||||||
case "USB"
|
|
||||||
mountusb
|
|
||||||
|
|
||||||
case "Android"
|
|
||||||
mountandroid
|
|
||||||
|
|
||||||
case "CD"
|
|
||||||
mountcd
|
|
||||||
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
switch (wc -l < $TMPDRIVES)
|
|
||||||
|
|
||||||
case 0
|
|
||||||
notify-send "No USB drive or Android device or CD detected" -a "dmount"
|
|
||||||
|
|
||||||
case 1
|
|
||||||
switch (cat $TMPDRIVES)
|
|
||||||
|
|
||||||
case "USB"
|
|
||||||
mountusb
|
|
||||||
case "Android"
|
|
||||||
mountandroid
|
|
||||||
case "CD"
|
|
||||||
mountCD
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
case '*'
|
|
||||||
asktype
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
rm -f $TMPDRIVES
|
|
@ -1,35 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
|
|
||||||
for arg in $argv
|
|
||||||
switch $arg
|
|
||||||
case '--type'
|
|
||||||
set -g TYPE "yes"
|
|
||||||
case '-t'
|
|
||||||
set -g TYPE "yes"
|
|
||||||
case 'type'
|
|
||||||
set -g TYPE "yes"
|
|
||||||
case '*'
|
|
||||||
printf 'Unknown argument: %s\n.' $arg
|
|
||||||
exit 1
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
set passwords (find $HOME/.password-store -type f -name "*.gpg" | \
|
|
||||||
string replace -r ".*.password-store/" "" | \
|
|
||||||
string replace -r ".gpg" "" | sort)
|
|
||||||
|
|
||||||
set password (for elem in $passwords
|
|
||||||
echo $elem
|
|
||||||
end | rofi -dmenu -i -p "Select your password")
|
|
||||||
|
|
||||||
if test -z $password
|
|
||||||
exit
|
|
||||||
end
|
|
||||||
|
|
||||||
if test $TYPE = "yes"
|
|
||||||
set -l IFS
|
|
||||||
set pass (pass show $password | string split -n \n)[1]
|
|
||||||
printf %s $pass | xvkbd -file -
|
|
||||||
else
|
|
||||||
pass show -c $password 2> /dev/null
|
|
||||||
end
|
|
@ -1,89 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
|
|
||||||
set -g drives (lsblk -nrpo "name,type,size,mountpoint" | \
|
|
||||||
awk '$2=="part"&&$4!~/\/boot|\/home$|SWAP/&&length($4)>1{printf "%s (%s)\n",$4,$3}')
|
|
||||||
|
|
||||||
set -g androids (awk '/jmtpfs/ {print $2}' /etc/mtab)
|
|
||||||
|
|
||||||
set -g cds (awk '/sr0/ {print $2}' /etc/mtab)
|
|
||||||
|
|
||||||
set -g undrivefile /tmp/undrives
|
|
||||||
|
|
||||||
rm -f $undrivefile
|
|
||||||
touch $undrivefile
|
|
||||||
|
|
||||||
test -n "$drives" && echo "USB" >> $undrivefile
|
|
||||||
test -n "$cds" && echo "CD" >> $undrivefile
|
|
||||||
test -n "$androids" && echo "Android" >> $undrivefile
|
|
||||||
|
|
||||||
function unmountusb
|
|
||||||
|
|
||||||
set chosen (echo $drives | \
|
|
||||||
rofi -dmenu -i -p "Unmount which drive?" | \
|
|
||||||
awk '{print $1}')
|
|
||||||
|
|
||||||
test -z "$chosen" && exit 0
|
|
||||||
|
|
||||||
sudo -A umount $chosen && \
|
|
||||||
notify-send "💻 USB unmounting" "$chosen unmounted." -a "dumount"
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function unmountandroid
|
|
||||||
|
|
||||||
set chosen (echo $androids | rofi -dmenu -i -p "Unmount which device?")
|
|
||||||
|
|
||||||
test -z "$chosen" && exit 0
|
|
||||||
|
|
||||||
sudo -A umount -l $chosen && \
|
|
||||||
notify-send "🤖 Android unmounting" "$chosen unmounted." -a "dumount"
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function unmountcd
|
|
||||||
|
|
||||||
set chosen (echo "$cds" | rofi -dmenu -i -p "Unmount which CD?")
|
|
||||||
|
|
||||||
test -z "$chosen" && exit 0
|
|
||||||
|
|
||||||
sudo -A umount -l $chosen && \
|
|
||||||
notify-send "💿 CD unmounting" "$chosen unmounted." -a "dumount"
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function asktype
|
|
||||||
|
|
||||||
switch (cat $undrivefile | rofi -dmenu -i -p "Unmount which type of device?")
|
|
||||||
|
|
||||||
case 'USB'
|
|
||||||
unmountusb
|
|
||||||
case 'CD'
|
|
||||||
unmountcd
|
|
||||||
case 'Android'
|
|
||||||
unmountandroid
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
switch (wc -l < $undrivefile)
|
|
||||||
|
|
||||||
case 0
|
|
||||||
notify-send "No USB drive or Android device or CD to unmount" -a "dumount"
|
|
||||||
|
|
||||||
case 1
|
|
||||||
switch (cat $undrivefile)
|
|
||||||
case 'USB'
|
|
||||||
unmountusb
|
|
||||||
case 'CD'
|
|
||||||
unmountcd
|
|
||||||
case 'Android'
|
|
||||||
unmountandroid
|
|
||||||
end
|
|
||||||
|
|
||||||
case '*'
|
|
||||||
asktype
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
rm -f $undrivefile
|
|
@ -1,2 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
telnet towel.blinkenlights.nl
|
|
@ -1,66 +0,0 @@
|
|||||||
#!/usr/bin/env fish
|
|
||||||
|
|
||||||
function set_device
|
|
||||||
|
|
||||||
set -g DEVICE "Wacom USB Bamboo PAD Pen stylus"
|
|
||||||
set -g DEVICETOUCH "Wacom USB Bamboo PAD Finger touch"
|
|
||||||
|
|
||||||
set -g WACOMPROPTOUCHSPEED "Device Accel Velocity Scaling"
|
|
||||||
set -g WACOMPROPSCROLLPSEED "ScrollDistance"
|
|
||||||
|
|
||||||
xsetwacom set "$DEVICE" ResetArea
|
|
||||||
|
|
||||||
set -l AREATOT (xsetwacom get "$DEVICE" Area)
|
|
||||||
set -g AREAX (echo $AREATOT | awk '{print $3}')
|
|
||||||
set -g AREAY (echo $AREATOT | awk '{print $4}')
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function set_screen
|
|
||||||
|
|
||||||
set CONNECTED_DISPLAYS (xrandr -q --current | \
|
|
||||||
sed -n 's/^\([^ ]\+\) connected .*/\1/p') desktop
|
|
||||||
|
|
||||||
set -g SCREEN (for d in $CONNECTED_DISPLAYS
|
|
||||||
echo $d
|
|
||||||
end | rofi -dmenu -i -p "Select your dispaly" | tr -d '\n')
|
|
||||||
|
|
||||||
set -l LINE (xrandr -q --current | if [ "$SCREEN" = "desktop" ]
|
|
||||||
sed -n 's/^Screen 0:.*, current \([0-9]\+\) x \([0-9]\+\),.*/\1 \2/p'
|
|
||||||
else
|
|
||||||
sed -n "s/^$SCREEN"' connected \(primary \)\{0,1\}\([0-9]\+\)x\([0-9]\+\)+.*/\2 \3/p'
|
|
||||||
end)
|
|
||||||
|
|
||||||
echo $LINE | read -g WIDTH HEIGHT
|
|
||||||
|
|
||||||
if test -z $WIDTH || test -z $HEIGHT
|
|
||||||
exit 1
|
|
||||||
end
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function adjust_device
|
|
||||||
|
|
||||||
set RATIOAREAY (math ceil \($AREAX \* $HEIGHT \/ $WIDTH\))
|
|
||||||
set RATIOAREAX (math ceil \($AREAY \* $WIDTH \/ $HEIGHT\))
|
|
||||||
|
|
||||||
if test $AREAY -gt $RATIOAREAY
|
|
||||||
set -g NEWAREAX $AREAX
|
|
||||||
set -g NEWAREAY $RATIOAREAY
|
|
||||||
else
|
|
||||||
set -g NEWAREAX $RATIOAREAX
|
|
||||||
set -g NEWAREAY $AREAY
|
|
||||||
end
|
|
||||||
|
|
||||||
xsetwacom set "$DEVICE" Area 0 0 $NEWAREAX $NEWAREAY
|
|
||||||
xsetwacom set "$DEVICE" MapToOutput "$SCREEN"
|
|
||||||
|
|
||||||
xinput set-float-prop $DEVICETOUCH $WACOMPROPTOUCHSPEED 0.5
|
|
||||||
|
|
||||||
xsetwacom set $DEVICETOUCH $WACOMPROPSCROLLPSEED "90"
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
set_device
|
|
||||||
set_screen
|
|
||||||
adjust_device
|
|
Loading…
Reference in New Issue
Block a user