forked from stuartcryan/lastpass-alfred-workflow
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "info.plist: allow for ports-installed lpass"
- Loading branch information
1 parent
b7af05f
commit adbbd83
Showing
2 changed files
with
5 additions
and
36 deletions.
There are no files selected for viewing
Binary file not shown.
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 |
---|---|---|
|
@@ -109,12 +109,7 @@ | |
<string>killall -9 lpass > /dev/null 2>&1 | ||
clear | ||
launchctl setenv LPASS_AGENT_TIMEOUT 28800 && export LPASS_AGENT_TIMEOUT=28800 | ||
for f in /usr/local/bin/lpass /opt/local/bin/lpass; do | ||
if test -x $f; then | ||
lpass_exec=$f | ||
fi | ||
done | ||
$lpass_exec login --trust "[email protected]" && exit</string> | ||
/usr/local/bin/lpass login --trust "[email protected]" && exit</string> | ||
</dict> | ||
<key>type</key> | ||
<string>alfred.workflow.action.terminalcommand</string> | ||
|
@@ -180,13 +175,7 @@ if ($details[0] eq 'error-noinstall'){ | |
exit 1; | ||
} else { | ||
my $lpass_exec; | ||
foreach my $f (qw@/usr/local/bin/lpass /opt/local/bin/lpass@) { | ||
$lpass_exec = $f | ||
if (-x $f); | ||
} | ||
my $results = qx{$lpass_exec show -c --username $details[1]}; | ||
my $results = qx{/usr/local/bin/lpass show -c --username $details[1]}; | ||
print $details[0]; | ||
}</string> | ||
|
@@ -236,16 +225,8 @@ my ($agent, $agentErr, $agentErrCode) = capture { | |
system('ps -ef | grep "lpass \[agent\]" | grep -v grep | grep -v "perl"'); | ||
}; | ||
my $lpass_exec; | ||
foreach my $f (qw@/usr/local/bin/lpass /opt/local/bin/lpass@) { | ||
$lpass_exec = $f | ||
if (-x $f); | ||
} | ||
my ($results, $err, $errorCode) = capture { | ||
system('TERM=xterm-256color && ' . | ||
$lpass_exec . ' sync && ' . | ||
$lpass_exec . ' ls --sync=no | grep -i ' . $search); | ||
system('TERM=xterm-256color && /usr/local/bin/lpass sync && /usr/local/bin/lpass ls --sync=no | grep -i ' . $search); | ||
}; | ||
print qq{<?xml version="1.0"?>\n<items>\n}; | ||
|
@@ -339,13 +320,7 @@ exit 0; | |
exit 1; | ||
} else { | ||
my $lpass_exec; | ||
foreach my $f (qw@/usr/local/bin/lpass /opt/local/bin/lpass@) { | ||
$lpass_exec = $f | ||
if (-x $f); | ||
} | ||
my $results = qx{$lpass_exec show -c --password $details[1]}; | ||
my $results = qx{/usr/local/bin/lpass show -c --password $details[1]}; | ||
print $details[0]; | ||
}</string> | ||
|
@@ -386,13 +361,7 @@ print $details[0]; | |
<key>escaping</key> | ||
<integer>127</integer> | ||
<key>script</key> | ||
<string> | ||
for f in /usr/local/bin/lpass /opt/local/bin/lpass; do | ||
if test -x $f; then | ||
lpass_exec=$f | ||
fi | ||
done | ||
$lpass_exec logout --force</string> | ||
<string>/usr/local/bin/lpass logout --force</string> | ||
<key>type</key> | ||
<integer>0</integer> | ||
</dict> | ||
|