Jump to content

ostertoaster

Member
  • Posts

    9
  • Joined

  • Last visited

Everything posted by ostertoaster

  1. So I have a variation on this, where I don't want to use Large Type. I think there's a very straightforward way to resolve this, since I only want display two lines. If I can get my script to feed the "Title" and "Text" in Post Notification, I'm set. Here's the shell script: QUERY={query} HOSTC=`host $QUERY | awk '{printf $NF}'` echo $HOSTC | /usr/bin/grep -q "NXDOMAIN" if [ $? -eq 0 ] ;then $result="$host not found" else ${var:result}="$HOSTC" fi I figure I can set Title to "{query}" but I need to be able to somehow get the script output to Text in Post Notification. Thoughts? Mike
  2. It looks like the list of Keychain Items might be achieved using a Script Filter? I checked the Alfred 2 workflow tutorials page, but found this feature's page empty. I'm happy to peruse through the forums, but want to make sure I'm headed down the right rabbit hole before I do.
  3. Not yet. The workflow would need a keyword to trigger the workflow, then filter a list of potential keychain entries. Selecting a keychain entry would then trigger the script to unlock and copy the password. Do you know of a plugin I could look at to figure out that second part--filtering a list of possible entries? The list would come out of a shell script that is running the "security dump-keychain" command. I certainly am not asking for anyone to write a workflow for me, but rather looking for an example to start from in the (internet) age-old cookbook tradition. Thank you, Mike
  4. Hi Andrew, I realize you're responding to jpotterm, but I do in fact have a PowerPack. I responded to your query about what workflow action type I'm using, and I responded that I'm not using a workflow and provided more details. If there's a way to wrap these apps or perform that same action--getting the password from specific Keychain entries--in a workflow, I'd be happy to work on converting over to that if it means that the focus issue would be resolved. All I'd ask is a pointer to what workflow action(s) would be most effective, or a pointer to an existing workflow that could serve as an example. Thank you, Mike
  5. Andrew, sorry for the major lag in responding. It's not a workflow, but an actual app that gets invoked via Alfred. Under the hood, it's an app bundle that invokes a shell script: Where KeychainEntry is the name of the entry in the Keychain, the shell scrip is located here: [KeychainEntry].app/Contents/MacOS/[KeychainEntry] #!/bin/bash PW=`python -c "print '$0'.split('/')[-1],"` ~/bin/getpw "$PW" |pbcopy If the Keychain is unlocked, then it will simply copy the entry password. If it hasn't been unlocked, you must first authenticate to unlock it. It worked (and continues to work) flawless in Alfred 1.x, in the sense that focus always ends up coming back to the pre-invocation window, which is usually Terminal.app or iTerm.app. If you think Keychain entries can be access in this fashion using a workflow, I'm more than happy to head down that rabbit hole. The important thing would be that it behave like 1Password integration in that individual entries would come up in search. As I did for David, I'm happy to send a manifesto of how the framework functions. There's a master app (refreshallpw) that uses the shell command "security dump-keychain" to find all entries of interest and generate the individual .app bundles for each entry. Thanks for any light you can shed on this, or any path forward!
  6. Checking in to see on the status of this one after seeing the 2.0.7 release email. Many updates later, this is still a problem, and it's keeping a couple colleagues stuck on Alfred 1.x (I'm just living with it). Happy to resend the script to the Alfred Team to help reproduce the issue.
  7. Hi David, Sure! What's the best way to get the files to you? -Mike
  8. Prior to upgrading to version 2, here is how a collection of apps worked: I would be in Terminal or iTerm, connecting to an SSH server When the SSH password prompt would come up, I would: Trigger Alfred v1 Type in the name of the app, which is a wrapper around a command line argument built for a specific keychain item The app would launch, and if I hadn't unlocked the keychain recently (based on timeout) I would enter my keychain password The script would pipe the password to the pbcopy command When the prior would finish, I'd have focus back in the terminal app, and could Command+V paste the password After upgrading to v2, the above still works, but after the pbcopy cmmand completes, I don't have focus back in the terminal application. :/ This has been replicable on all Alfred builds through 2.0.1 (haven't had an opportunity to try 2.0.2 as I don't have that computer). The OS is the latest release of Lion (10.7), though a colleague of mine who uses the same thing experienced the same thing on the latest release of Mountain Lion (10.8). Maybe there's a way to remove the need for this with workflows (not sure if the CLI that does the heavy lifting can be made to return results for a script filter?) but getting back focus would be an easy and welcome fix. Thanks! Mike
×
×
  • Create New...