Jump to content

"Hooks" for "Lock" action?


Recommended Posts

Is there a way to tie my shell/python/whatever script in with Alfred's "Lock" action?

 

In the immediate instance, I'd like to clear all SSH keys and revoke sudo access when I lock the console. The shell commands to achieve this would be "ssh-add -Dx ; sudo -nK". For my purposes it wouldn't matter whether the script gets run before or after the console is actually locked.

 

Link to comment

Is there a way to tie my shell/python/whatever script in with Alfred's "Lock" action?

 

In the immediate instance, I'd like to clear all SSH keys and revoke sudo access when I lock the console. The shell commands to achieve this would be "ssh-add -Dx ; sudo -nK". For my purposes it wouldn't matter whether the script gets run before or after the console is actually locked.

 

There isnt a hook from Alfred for that but you can make a workflow that ran your script then executed the lock system command. Then you can disable the built in lock command

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...