Skip to content
Permalink
Browse files

bicc

  • Loading branch information...
neeasade committed Sep 4, 2019
1 parent f3e314a commit 69c5daaeac2a22687d8bca202780b71e2da571d5
Showing with 29 additions and 17 deletions.
  1. +1 −0 shell/.sh.d/environment
  2. +25 −14 shell/.sh.d/functions
  3. +1 −1 wm/.wm/panel/lemons/battery
  4. +2 −2 wm/.wm/scripts/theming/ltheme
@@ -85,6 +85,7 @@ succ .go/bin
succ .cargo/bin
succ .wm/scripts/interact
succ .wm/scripts/visual
succ .wm/panel/lemons
# pip --user location
succ .local/bin

@@ -8,6 +8,10 @@ sysinfo() {
printf "\n%s\n%s\n\n" "$(pcs)" "$(pcs '1;')"
}

bicc() {
du -Sa "${1:-$HOME}" | sort -n -r | head -n 20 | awk '{"numfmt --to=si "$1"000" | getline size; $1=""; print size $0}'
}

sleepm() {
sleep $(($1 * 60))
}
@@ -211,26 +215,32 @@ passadd() {
}

gset() {
g_conf() {
echo git config user.name "$1"
git config user.name "$1"
echo git config user.email "$2"
git config user.email "$2"
}

if [ ! -z "$2" ]; then
g_conf "$1" "$2"
return
fi

case $1 in
pass)
git config user.name "$(pass git/name)"
git config user.email "$(pass git/email)"
;;
pass) g_conf "$(pass git/name)" "$(pass git/email)" ;;
manual)
echo name:; read _name
git config user.name "$_name"

echo email:; read _email
git config user.email "$_email"
echo name:; read name
echo email:; read email
g_conf "$name" "$email"
;;
adhoc)
_name="$(getent passwd "$USER" | cut -d ':' -f 5 | sed 's/,//g')"
_name="${name:-$USER}"
git config user.name "$_name"
git config user.email "${USER}@$(hostname).machine"
name="$(getent passwd "$USER" | cut -d ':' -f 5 | sed 's/,//g')"
g_conf "${name:-$USER}" "${USER}@$(hostname).machine"
;;
*)
echo options: pass home adhoc
echo "gset <name> <email>"
echo "or: gset manual|adhoc|pass"
;;
esac
}
@@ -241,6 +251,7 @@ ttemp() {

mkdir -p "${working_dir}/${current}"
cd "${working_dir}/${current}"
pwd

if [ ! -z "$*" ]; then
echo "$*" > ./context.txt
@@ -1,4 +1,4 @@
#!/usr/bin/env dash
#!/bin/sh

icon battery

@@ -214,8 +214,8 @@ load_qutebrowser() {
margs qutebrowser .config/qutebrowser/config.py

# bspc config ignore_ewmh_focus true
qb_command ':config-source'
qb_command ':reload' # reload current page w/ css
# qb_command ':config-source'
# qb_command ':reload' # reload current page w/ css
# bspc config ignore_ewmh_focus false
}

0 comments on commit 69c5daa

Please sign in to comment.
You can’t perform that action at this time.