Skip to content

Commit

Permalink
put keyboard check in main function
Browse files Browse the repository at this point in the history
  • Loading branch information
carnager committed Aug 30, 2016
1 parent b0406cd commit 8945b01
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions rofi-pass
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,6 @@ help="Alt+h"
switch="Alt+x"
insert_pass="Alt+n"

if [[ -n $keyboard ]]; then
setxkbmap "${keyboard}"
fi

# get all password files and create an array
list_passwords() {
Expand Down Expand Up @@ -535,6 +532,10 @@ if [[ ! -d "$HOME/.cache/rofi-pass" ]]; then
mkdir "$HOME/.cache/rofi-pass"
fi

if [[ -n $keyboard ]]; then
setxkbmap "${keyboard}"
fi

# set help color
if [[ $help_color == "" ]]; then
help_color=$(rofi -dump-xresources | grep 'rofi.color.normal' | gawk -F ',' '/,/{gsub(/ /, "", $2); print $2}')
Expand Down

0 comments on commit 8945b01

Please sign in to comment.