summaryrefslogtreecommitdiff
path: root/.local/bin
diff options
context:
space:
mode:
Diffstat (limited to '.local/bin')
-rwxr-xr-x.local/bin/aurignored16
-rwxr-xr-x.local/bin/barlaunch7
-rwxr-xr-x.local/bin/barpos36
-rwxr-xr-x.local/bin/comptoggle7
-rwxr-xr-x.local/bin/in-git-repo9
-rwxr-xr-x.local/bin/key4
-rwxr-xr-x.local/bin/lock9
-rwxr-xr-x.local/bin/screenshot25
-rwxr-xr-x.local/bin/statusbar/sb-forecast49
-rwxr-xr-x.local/bin/statusbar/sb-packages22
10 files changed, 0 insertions, 184 deletions
diff --git a/.local/bin/aurignored b/.local/bin/aurignored
deleted file mode 100755
index efb12f7..0000000
--- a/.local/bin/aurignored
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-# Get list of ignored pkgs
-ignored() {
- pkgs="$(grep IgnorePkg /etc/pacman.conf | sed -e 's/IgnorePkg =//' -e 's/#.*//')"
- grps="$(grep IgnoreGroup /etc/pacman.conf | sed -e 's/IgnoreGroup =//' -e 's/#.*//')"
- [ -n "$grps" ] && pkgs="$pkgs $(pacman -Sgq "$grps")"
-
- echo -n "$pkgs" | tail -n -1
-}
-
-# Return only AUR pkgs
-for pkg in $(ignored)
-do
- pacman -Si "$pkg" >/dev/null 2>&1 || echo "$pkg"
-done
diff --git a/.local/bin/barlaunch b/.local/bin/barlaunch
deleted file mode 100755
index 99a37cd..0000000
--- a/.local/bin/barlaunch
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-polybar-msg cmd quit >/dev/null
-
-echo "---" >> /tmp/polybar.log
-MONITOR=eDP-1 nohup polybar primary --reload >> /tmp/polybar.log 2>&1 &
-# MONITOR=HDMI-1 nohup polybar primary --reload >> /tmp/polybar.log 2>&1 &
diff --git a/.local/bin/barpos b/.local/bin/barpos
deleted file mode 100755
index 66f29de..0000000
--- a/.local/bin/barpos
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-BAR_CFG="$XDG_CONFIG_HOME/polybar/config.ini"
-
-main () {
- if [ -z "$1" ]; then
- toggle ; exit 0
- fi
-
- case "$1" in
- t|top)
- top ;;
- b|bottom)
- bottom ;;
- *)
- echo "usage: barpos [top|bottom]" ;;
- esac
-}
-
-toggle () {
- if grep -Eq "^bottom = true$" "$BAR_CFG"; then
- top
- else
- bottom
- fi
-}
-
-bottom () {
- sed -Ei "s|^bottom = .*$|bottom = true|" "$BAR_CFG"
-}
-
-top () {
- sed -Ei "s|^bottom = .*$|bottom = false|" "$BAR_CFG"
-}
-
-main "$@"
diff --git a/.local/bin/comptoggle b/.local/bin/comptoggle
deleted file mode 100755
index 438ac32..0000000
--- a/.local/bin/comptoggle
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-if pgrep -x "picom" >/dev/null; then
- killall picom
-else
- picom -b --config "$HOME/.config/picom/picom.conf"
-fi
diff --git a/.local/bin/in-git-repo b/.local/bin/in-git-repo
deleted file mode 100755
index 0372e32..0000000
--- a/.local/bin/in-git-repo
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/sh
-
-res=$(git rev-parse --is-inside-work-tree 2>/dev/null)
-
-if [ "$res" = true ]; then
- exit 0
-else
- exit 1
-fi
diff --git a/.local/bin/key b/.local/bin/key
deleted file mode 100755
index d37c407..0000000
--- a/.local/bin/key
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-
-systemctl restart keyd.service
-rate &
diff --git a/.local/bin/lock b/.local/bin/lock
deleted file mode 100755
index 7f2c145..0000000
--- a/.local/bin/lock
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/sh
-
-xset dpms 10
-xidlehook \
- --detect-sleep --not-when-audio --not-when-fullscreen \
- --timer 60 'systemctl suspend' '' &
-slock
-kill $!
-xset -dpms
diff --git a/.local/bin/screenshot b/.local/bin/screenshot
deleted file mode 100755
index 04b28cd..0000000
--- a/.local/bin/screenshot
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/sh
-
-main () {
- if [ $# -eq 0 ]; then
- print_screen ; exit 0
- fi
-
- case "$1" in
- -s)
- selection ;;
- *)
- echo "usage: screenshot [-s]" ;;
- esac
-}
-
-print_screen () {
- scrot -q 100 -e 'xclip -selection c -t image/png < $f; mv $f ~/Pictures/screenshots/'
-}
-
-selection () {
- sleep 0.2
- scrot -l mode=edge -i -s -e 'xclip -sel clip -t image/png $f; mv $f ~/Pictures/screenshots/'
-}
-
-main "$@"
diff --git a/.local/bin/statusbar/sb-forecast b/.local/bin/statusbar/sb-forecast
deleted file mode 100755
index c9923fd..0000000
--- a/.local/bin/statusbar/sb-forecast
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/sh
-
-LOCATION=$(cat "$XDG_CONFIG_HOME/forecast/location")
-
-main () {
- case "$1" in
- -b|--browser)
- xdg-open "https://wttr.in/$LOCATION"
- exit 0 ;;
- esac
-
- res=$(curl -sf wttr.in/"$LOCATION"?format="%x+%t") || exit 1
-
- icon=$(condition_icon "$res")
- temp=$(temperature "$res")
- echo "$icon" "$temp"
-}
-
-condition_icon () {
- icon=$(echo "$1" | cut -d\ -f1)
-
- case "$icon" in
- '=') echo  ;;
- '/') echo  ;;
- '.') echo  ;;
- 'm') echo  ;;
- 'o') echo  ;;
- 'mmm') echo  ;;
- 'mm') echo  ;;
- '///') echo  ;;
- '//') echo  ;;
- '**') echo  ;;
- '*') echo  ;;
- '*/*') echo  ;;
- 'x') echo  ;;
- 'x/') echo  ;;
- '*/') echo  ;;
- '/!/') echo  ;;
- '!/') echo  ;;
- '*!*') echo  ;;
- *) echo ? ;;
- esac
-}
-
-temperature () {
- echo "$1" | cut -d\ -f2 | sed -e 's/+//' -e 's/-0/0/' -e 's/C//'
-}
-
-main "$@"
diff --git a/.local/bin/statusbar/sb-packages b/.local/bin/statusbar/sb-packages
deleted file mode 100755
index bbdefb1..0000000
--- a/.local/bin/statusbar/sb-packages
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-
-if ! updates_arch=$(checkupdates 2> /dev/null | wc -l ); then
- updates_arch=0
-fi
-
-# if ! updates_aur=$(yay -Qum 2> /dev/null | wc -l); then
-if ! updates_aur=$(paru -Qum 2> /dev/null | wc -l); then
-# if ! updates_aur=$(cower -u 2> /dev/null | wc -l); then
-# if ! updates_aur=$(trizen -Su --aur --quiet | wc -l); then
-# if ! updates_aur=$(pikaur -Qua 2> /dev/null | wc -l); then
-# if ! updates_aur=$(rua upgrade --printonly 2> /dev/null | wc -l); then
- updates_aur=0
-fi
-
-aur_ignored=$($HOME/.local/bin/aurignored | wc -l)
-
-updates=$((updates_arch + updates_aur - $aur_ignored))
-
-if [ "$updates" -gt 0 ]; then
- echo " $updates"
-fi