diff options
-rwxr-xr-x | dwm/Scripts/lc (renamed from dwm/lc) | 0 | ||||
-rw-r--r-- | dwm/Scripts/runStat.sh | 6 | ||||
-rw-r--r-- | initFolders.sh | 6 | ||||
-rw-r--r-- | scripts/Scripts/passmenu | 28 | ||||
-rw-r--r-- | setup.sh | 8 | ||||
-rw-r--r-- | zsh/.zshrc | 6 |
6 files changed, 44 insertions, 10 deletions
diff --git a/dwm/Scripts/runStat.sh b/dwm/Scripts/runStat.sh new file mode 100644 index 0000000..52b0536 --- /dev/null +++ b/dwm/Scripts/runStat.sh @@ -0,0 +1,6 @@ +elements="ram.sh status.sh mic.sh" + +if [ $1 = "dmenu" ]; then + sh $(echo $elements | tr " " "\n" | dmenu -i -p ":") +fi + diff --git a/initFolders.sh b/initFolders.sh new file mode 100644 index 0000000..30cf3de --- /dev/null +++ b/initFolders.sh @@ -0,0 +1,6 @@ +# Add folders that should not be symlinked by stow + +mkdir -p ~/Scripts +mkdir -p ~/Scripts/enMenuScripts +mkdir -p ~/.config/qutebrowser +mkdir -p ~/.config/nvim diff --git a/scripts/Scripts/passmenu b/scripts/Scripts/passmenu new file mode 100644 index 0000000..0cc80e6 --- /dev/null +++ b/scripts/Scripts/passmenu @@ -0,0 +1,28 @@ +#!/usr/bin/env bash + +shopt -s nullglob globstar + +typeit=0 +if [[ $1 == "--type" ]]; then + typeit=1 + shift +fi + +prefix=${PASSWORD_STORE_DIR-~/.password-store} +password_files=( "$prefix"/**/*.gpg ) +password_files=( "${password_files[@]#"$prefix"/}" ) +password_files=( "${password_files[@]%.gpg}" ) + +password=$(printf '%s\n' "${password_files[@]}" | dmenu "$@") + +[[ -n $password ]] || exit + +if [[ $typeit -eq 0 ]]; then + pass show -c "$password" 2>/dev/null +else + pass show "$password" | { IFS= read -r pass; printf %s "$pass"; } | + xdotool type --clearmodifiers --file - +fi + +notify-send "Done" +pass $password | grep login | cut -d' ' -f2- | xclip -selection c diff --git a/setup.sh b/setup.sh deleted file mode 100644 index 7470d40..0000000 --- a/setup.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -# Install oh-my-zsh -sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" - -rm -rf ../.zshrc - -stow zsh @@ -32,10 +32,10 @@ ZSH_THEME="af-magic" # DISABLE_AUTO_TITLE="true" # Uncomment the following line to enable command auto-correction. -# ENABLE_CORRECTION="true" +ENABLE_CORRECTION="true" # Uncomment the following line to display red dots whilst waiting for completion. -# COMPLETION_WAITING_DOTS="true" +COMPLETION_WAITING_DOTS="true" # Uncomment the following line if you want to disable marking untracked files # under VCS as dirty. This makes repository status check for large repositories @@ -156,3 +156,5 @@ command_not_found_handler () { # opam configuration test -r /home/julian/.opam/opam-init/init.zsh && . /home/julian/.opam/opam-init/init.zsh > /dev/null 2> /dev/null || true export ANSIBLE_NOCOWS=1 + +export PATH=$HOME/Scripts:$PATH |