summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornic <ra@afu.re>2024-05-11 22:41:54 -0400
committernic <ra@afu.re>2024-05-11 22:41:54 -0400
commit41111989d02a6ad1e66b37dc58a21dd761d8f573 (patch)
tree353697dd6a7e5d63c1fa48cf722881649a47cd26
parenta2715adbab22946bd168d07c5264e1b8b4c9288f (diff)
now using sudo
-rw-r--r--.config/nvim/init.vim6
-rw-r--r--.config/shell/profile2
-rw-r--r--.config/x11/xprofile6
-rwxr-xr-x.local/bin/ib-tws12
-rwxr-xr-x.local/bin/mounter12
5 files changed, 18 insertions, 20 deletions
diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim
index c707c68..4a8f775 100644
--- a/.config/nvim/init.vim
+++ b/.config/nvim/init.vim
@@ -29,7 +29,7 @@ set noswapfile
set nobackup
colorscheme molokai
-" make it so theme as no black background like default
+" make it so molokai respect xcompmgr
hi Normal ctermbg=NONE
hi NonText ctermbg=NONE
@@ -67,8 +67,8 @@ hi NonText ctermbg=NONE
" Runs a script that cleans out tex build files whenever I close out of a .tex file.
autocmd VimLeave *.tex !texclear %
-" Save file as doas? on files that require root permission
-" cabbrev w!! execute 'silent! write !doas tee % >/dev/null' <bar> edit!
+" Save file as sudo on files that require root permission
+ cabbrev w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit!
" Bindings
" Spell-check set to <leader>o, 'o' for 'orthography':
diff --git a/.config/shell/profile b/.config/shell/profile
index 4a58f2e..d4479b0 100644
--- a/.config/shell/profile
+++ b/.config/shell/profile
@@ -44,4 +44,4 @@ export W3M_DIR="$XDG_CONFIG_HOME/w3m"
[ "$(tty)" = "/dev/tty1" ] && ! pidof -s Xorg >/dev/null 2>&1 && exec startx "$XINITRC"
# Switch escape and caps lock
-doas loadkeys ${XDG_DATA_HOME:-$HOME/.local/share}/ttymaps.kmap 2>/dev/null
+sudo -n loadkeys ${XDG_DATA_HOME:-$HOME/.local/share}/ttymaps.kmap 2>/dev/null
diff --git a/.config/x11/xprofile b/.config/x11/xprofile
index 5a3a21c..aff206e 100644
--- a/.config/x11/xprofile
+++ b/.config/x11/xprofile
@@ -3,11 +3,9 @@
# If you use startx/xinit, this file will also be sourced.
xrandr --output DP-4 --mode 1920x1080 --rate 240
-setbg &
-slstatus &
-autostart="dunst mpd xcompmgr unclutter remapd"
-#gentoo-pipewire-launcher
+autostart="gentoo-pipewire-launcher setbg dunst mpd xcompmgr unclutter remapd"
+
for program in $autostart; do
pidof -sx "$program" || "$program" &
done >/dev/null 2>&1
diff --git a/.local/bin/ib-tws b/.local/bin/ib-tws
index 22fc22b..d8dbb01 100755
--- a/.local/bin/ib-tws
+++ b/.local/bin/ib-tws
@@ -1,14 +1,14 @@
-#!/bin/bash
+#!/bin/sh
V=1025
-#TWSUSERID=
-#TWSPASSWORD=$(pass)
-IBC_INI=$HOME/.local/src/Jts/ibc/config.ini
-IBC_PATH=$HOME/.local/src/Jts/ibc
TWS_PATH=$HOME/.local/src/Jts
TWS_SETTINGS_PATH=
+#TWS_USER=
+#TWS_PASS=$(pass)
+IBC_INI=$HOME/.local/src/Jts/ibc/config.ini
+IBC_PATH=$HOME/.local/src/Jts/ibc
_2FA=exit # or ... ?
LOG_PATH=
JAVA_PATH=
-$HOME/.local/src/Jts/ibc/scripts/ibcstart.sh $V --tws-path=$TWS_PATH --tws-settings-path= --ibc-path=$IBC_PATH --ibc-ini=$IBC_INI --user= --pw= --fix-user= --fix-pw= --java-path= --mode= --on2fatimeout=$_2FA
+exec $HOME/.local/src/Jts/ibc/scripts/ibcstart.sh $V --tws-path=$TWS_PATH --tws-settings-path= --ibc-path=$IBC_PATH --ibc-ini=$IBC_INI --user= --pw= --fix-user= --fix-pw= --java-path= --mode= --on2fatimeout=$_2FA
diff --git a/.local/bin/mounter b/.local/bin/mounter
index 246680e..3972784 100755
--- a/.local/bin/mounter
+++ b/.local/bin/mounter
@@ -68,13 +68,13 @@ getmount(){
test -n "$mp"
if [ ! -d "$mp" ]; then
mkdiryn=$(printf "No\\nYes" | dmenu -i -p "$mp does not exist. Create it?")
- [ "$mkdiryn" = "Yes" ] && (mkdir -p "$mp" || doas mkdir -p "$mp")
+ [ "$mkdiryn" = "Yes" ] && (mkdir -p "$mp" || sudo -A mkdir -p "$mp")
fi
}
attemptmount(){
# Attempt to mount without a mountpoint, to see if drive is in fstab.
- doas mount "$chosen" || return 1
+ sudo -A mount "$chosen" || return 1
notify-send "💾Drive Mounted." "$chosen mounted."
exit
}
@@ -84,7 +84,7 @@ case "$chosen" in
chosen="${chosen%% *}"
chosen="${chosen:1}" # This is a bashism.
attemptmount || getmount
- doas mount "$chosen" "$mp" -o uid="$(id -u)",gid="$(id -g)"
+ sudo -A mount "$chosen" "$mp" -o uid="$(id -u)",gid="$(id -g)"
notify-send "💾Drive Mounted." "$chosen mounted to $mp."
;;
@@ -98,12 +98,12 @@ case "$chosen" in
done
# Decrypt in a terminal window
- ${TERMINAL:-st} -n floatterm -g 60x1 -e doas cryptsetup open "$chosen" "usb$num"
+ ${TERMINAL:-st} -n floatterm -g 60x1 -e sudo cryptsetup open "$chosen" "usb$num"
# Check if now decrypted.
test -b "/dev/mapper/usb$num"
attemptmount || getmount
- doas mount "/dev/mapper/usb$num" "$mp" -o uid="$(id -u)",gid="$(id -g)"
+ sudo -A mount "/dev/mapper/usb$num" "$mp" -o uid="$(id -u)",gid="$(id -g)"
notify-send "🔓Decrypted drive Mounted." "$chosen decrypted and mounted to $mp."
;;
@@ -112,7 +112,7 @@ case "$chosen" in
getmount
number="${chosen%%:*}"
number="${chosen:1}" # This is a bashism.
- doas simple-mtpfs -o allow_other -o fsname="simple-mtpfs-$(escape "$chosen")" --device "$number" "$mp"
+ sudo -A simple-mtpfs -o allow_other -o fsname="simple-mtpfs-$(escape "$chosen")" --device "$number" "$mp"
notify-send "🤖 Android Mounted." "Android device mounted to $mp."
;;
esac