-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support cli in flatpak wrapper script
- Loading branch information
Showing
1 changed file
with
7 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,10 +31,15 @@ readonly arg2='[email protected]' | |
|
||
# Browser integration is enabled if unix socket exists | ||
if [[ -S "${XDG_RUNTIME_DIR}/app/${appId}/${appId}.BrowserServer" ]]; then | ||
if [[ "$1" =~ "${arg1}" ]] || [[ "$2" =~ "${arg2}" ]]; then | ||
if [[ "$1" == "${arg1}" ]] || [[ "$2" == "${arg2}" ]]; then | ||
exec keepassxc-proxy "$@" | ||
fi | ||
fi | ||
|
||
# If no arguments are matched or browser integration is off execute keepassxc | ||
# If the first argument is "cli", execute keepassxc-cli instead. | ||
if [[ "$1" == "cli" ]]; then | ||
exec keepassxc-cli "${@:2}" | ||
fi | ||
|
||
# If no arguments are matched or browser integration is off, execute keepassxc | ||
exec keepassxc "$@" |