wofi-pass1
Pass support for wofi
Usage
wofi-pass [OPTIONS ...]
Options
-
-a, --autotype -
Autotype whatever entry is chosen.
-
-c, --copy [cmd] -
Copy to clipboard. Defaults to
wl-copyif no cmd is given.
-
-f, --fileisuser -
Use the name of the password file as username.
-
-h, --help -
Show the help message
-
-i, --insensitive -
Search for password in a case-insensitive way
-
-s, --squash -
Don't show field choice if password file only contains password.
-
-t, --type [cmd] -
Type the selection instead of copying to clipboard. Defaults to
wtypeif no cmd is given.
-
-k, --nohotkeys -
Disable the hotkeys support for wofi-pass. The hotkeys feature is by default enabled.
wofisupports the required custom keys feature from version v1.4. If you are using an olderwofiversion or awofialternative that does not have custom keys support at all, the hotkey feature can be disabled to avoid errors.
Configuration file
One way to customize the wofi-pass behavior is to change the configuration file. wofi-pass does not require a configuration file, but searches the following paths for a valid configuration file at every startup:
- •
-
${WOFI_PASS_CONFIG}
- •
-
${XDG_CONFIG_HOME}/wofi-pass/config
- •
-
/etc/wofi-pass.conf
wofi-pass only reads the first configuration file it finds. The order of searching is the same as in the list above.
If the environment variable ${XDG_CONFIG_HOME} is not set, it is replaced by the default value ${HOME}/.config.
Configuration variables
The following variables can be redefined in configuration file.
Common
PASSWORD_STORE_DIR-
Path to the pass storage files. Default:
${HOME}/.password-store
Commands
CMD_COPY-
Command to redirect the output to the clipboard. Default:
wl-copy
CMD_TYPE-
Command to type the output. Default: wcopy -
Pass fields
PASS_FIELD_USERNAME-
passfield to be used as username for autotype. Default:username
Hotkeys
HOTKEY_USERNAME-
Hotkey definition for direct selection of the username field. See wofi-keys(7) for the key codes. Default hotkey is
Alt-u.
HOTKEY_PASSWORD-
Hotkey definition for direct selection of the password field. See wofi-keys(7) for the key codes. Default hotkey is
Alt-p.
HOTKEY_AUTOTYPE-
Hotkey definition for direct selection of the autotype field. See wofi-keys(7) for the key codes. Default hotkey is
Alt-a.
HOTKEY_OTP-
Hotkey definition for direct selection of the OTP field. See wofi-keys(7) for the key codes. Default hotkey is
Alt-o.
Password files
wofi-pass assumes password files are formatted like the following:
-
Th3Gr3at3stPassw0rd username: JohnDoe email: [email protected] otpauth://totp/example?secret=ABCDCBABCDCBABCD pin: 1234
Note that the password is ALWAYS on the first line.
Autotype
The function autotype activates a formatted output of a pass entry.
The autotype function can be activated in 3 different ways:
- 1.
-
by setting the option
-athe selected entry will be output formatted
- 2.
-
selecting the field
autotypeor pressHOTKEY_AUTOTYPEhotkey will output the entry formatted
- 3.
-
adding the field
autotype_alwaysto thepassentry, this entry will always be output formatted.
Autotype format
The format of the autotype is by default is as follows:
username :tab pass
and is defined by WOFI_PASS_AUTOTYPE. The autotype format string consists of a combination of keywords and pass fields separated by a space. The keywords are the follows:
:tab-
Type the Tab-key if type mode active else output \t.
:space-
Type the Space-key if type mode active else output " ".
:enter-
Type the Enter-key if type mode active else output \n.
:delay-
Delay the output for a specified time. The time is defined by
WOFI_PASS_DELAYin seconds, where the default value is2seconds. Is only executed when type mode is active.
:otp-
Output the One Time Password
:password-
Output the password
:username-
Output the username field, defined by
PASS_FIELD_USERNAME
:path-
Output the filename of selected
:passentry
All other entries are interpreted as pass fields and output the contents of the respective field.
History
- Debian 13 (Trixie): the text shown here
- Debian 12 (Bookworm)
--insensitive since Debian 13 (Trixie);
--nohotkeys since Debian 13 (Trixie);
-i since Debian 13 (Trixie);
-k since Debian 13 (Trixie).