jmjeong Posted March 28, 2013 Posted March 28, 2013 (edited) Browse and Manage alfred extension (Download) Search and manage the installed extension. Usage alf :: display the installed extensionsalf <search> :: search extension by title, author name, and keywordenter :: Browse the installed folder in Alfredctrl :: Reveal the installed folder in Findershift :: Execute extension with the first keywordcmd :: Open terminal in the installed folderopt:: Export the extension for distribusion (Default: ~/Downloads, you can refine it in export.json file) export.json The file format is as follows: {"workflow-export" :{"directory" : "~/git/alfred-extension/managealfredextension","enable": true},"source-export":{"directory" : "~/git/alfred-extension/managealfredextension","enable": false}} 'workflow-export' specifies the directory where .alfredworkflow is exported. 'source-export' specifies the directory where extension source is copied. Version History 2.8 - July 16, 2014 Handles the title and author having space 2.6 - April 11, 2013 Handle subdirectory during export2.5 - April 8, 2013 Display hotkey informationHotkey information is borrowed from (com.help.shawn.rice) by Shawn Rice2.4 - April 1, 2013 Fix a bug about pathname with space2.3 - March 31, 2013 Sort title by alphabetically2.2 - March 29, 2013 Export feature : Default directory is ~/Downloads Toggle extensions with fn modifier Fix a bug in export function 2.0 - March 29, 2013 Export feature Open terminal Support Alleyoop's auto update plugin Display 'disabled' extension 1.x - March 28, 2013 Initial version Edited July 16, 2014 by jmjeong Carlos-Sz, twinpeaks, ClintonStrong and 7 others 10
vdesabou Posted March 28, 2013 Posted March 28, 2013 That's awesome, I will use it very often! However, it is not working on my side. Trying to execute the python script on command line, I get: python main.py "test" Traceback (most recent call last): File "main.py", line 31, in <module> keyword = ",".join([o['config']['keyword'] for o in plist['objects'] if 'alfred.workflow.input' in o['type'] ]) KeyError: 'keyword' Any idea how to fix this? Cheers jmjeong 1
jmjeong Posted March 28, 2013 Author Posted March 28, 2013 (edited) That's awesome, I will use it very often! However, it is not working on my side. Trying to execute the python script on command line, I get: python main.py "test" Traceback (most recent call last): File "main.py", line 31, in <module> keyword = ",".join([o['config']['keyword'] for o in plist['objects'] if 'alfred.workflow.input' in o['type'] ]) KeyError: 'keyword' Any idea how to fix this? Cheers I uploaded the extension again. Edited March 28, 2013 by jmjeong
vdesabou Posted March 28, 2013 Posted March 28, 2013 Thanks it is working fine now! This workflow is awesome ! It would be great to have also the hotkey, but I don't know if this is easy to get from the plist. Cheers!
jmjeong Posted March 28, 2013 Author Posted March 28, 2013 Thanks it is working fine now! This workflow is awesome ! It would be great to have also the hotkey, but I don't know if this is easy to get from the plist. Cheers! You can get hot key information from plist variable in main.py For example, Cntl-Command-E is represented as '{'type': 'alfred.workflow.trigger.hotkey', 'config': {'leftcursor': False, 'argument': 0, 'hotkey': 14, 'action': 0, 'hotstring': 'E', 'hotmod': 1310720, 'modsmode': 0}', but I don't know the whole information how to interpret.
ramiro.araujo Posted March 28, 2013 Posted March 28, 2013 Great!! I had this kind of extension planned to do, but my idea is to build an extension to browse other installed extensions, see their keywords and basic description, and launch them on enter (re-open Alfred with the keyword typed in). What do you think?
Benzi Posted March 28, 2013 Posted March 28, 2013 This is great! especially the option to open the workflow folder directly. If you path.join the workflow folder and "icon.png" and set that as the icon element value in the XML, you can see the icons for each workflow... Nice work!
jmjeong Posted March 28, 2013 Author Posted March 28, 2013 (edited) Great!! I had this kind of extension planned to do, but my idea is to build an extension to browse other installed extensions, see their keywords and basic description, and launch them on enter (re-open Alfred with the keyword typed in). What do you think? That's good idea. I updated the extension. In version 4, you can launch the selected extension with shift key. Edited March 28, 2013 by jmjeong
jmjeong Posted March 28, 2013 Author Posted March 28, 2013 This is great! especially the option to open the workflow folder directly. If you path.join the workflow folder and "icon.png" and set that as the icon element value in the XML, you can see the icons for each workflow... Nice work! Good Idea. I updated the extension to display its icon. Benzi 1
jmjeong Posted March 28, 2013 Author Posted March 28, 2013 Great!! I had this kind of extension planned to do, but my idea is to build an extension to browse other installed extensions, see their keywords and basic description, and launch them on enter (re-open Alfred with the keyword typed in). What do you think? If you download the new version, you can launch the selected extension with shift modifier.
nickvitale Posted March 28, 2013 Posted March 28, 2013 (edited) Oh thank god! 3 nights in a row I was going to put in a request for this and 3 times I hit the backspace key and lost my text, thank you so much! So valuable!! I just needed a way to view all my installed workflows without opening the Alfred Preferences pane. I'm a workflow addict. I'm not a developer and this tool has HUGE potential in my opinion. I'm sure you're well booked with other requests but it'd be great if there could be non-developer features added to it.. For instance, generating a link to share the creators URL The ability to open Alfred Preferences focused on that workflows, even if it just populates the search box for you It's awesome you got the keywords in, can you do the shortcut keys as well? I could probably go on and on... Thank you again, this is really so great! Thank you thank you! ### EDIT ### I was so excited I didn't even read the other posts. Now I see you can actually launch the workflow with the shift modifier. I don't know what to say. Thank you again, just awesome. Edited March 28, 2013 by nick Domenic 1
CarlosNZ Posted March 29, 2013 Posted March 29, 2013 Hmmm, this could be very useful, but for me it's getting stuck on "loading..." Nothing happens after that. jmjeong 1
jmjeong Posted March 29, 2013 Author Posted March 29, 2013 (edited) Hmmm, this could be very useful, but for me it's getting stuck on "loading..." Nothing happens after that. I hope version 5 will solve this problem. This happens when 'info.plist' does not exist. Edited March 29, 2013 by jmjeong
CarlosNZ Posted March 29, 2013 Posted March 29, 2013 I hope version 5 will solve this problem. This happens when 'info.plist' does not exist. Still a no go I'm afraid. I do have some workflows in my list disabled - any chance that might have something to do with it? jmjeong 1
jmjeong Posted March 29, 2013 Author Posted March 29, 2013 could you post the generated message by 'python main.py' in extension directory?
CarlosNZ Posted March 29, 2013 Posted March 29, 2013 (edited) Okay, when I run that from the command line, I get this: Traceback (most recent call last): File "main.py", line 29, in <module> plist = plistlib.readPlist(os.path.join(dirname, d, 'info.plist')) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 78, in readPlist rootObject = p.parse(pathOrFile) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 406, in parse parser.ParseFile(fileobj) xml.parsers.expat.ExpatError: no element found: line 1, column 0 Hope that's helpful. Edited March 29, 2013 by CarlosNZ
jmjeong Posted March 29, 2013 Author Posted March 29, 2013 (edited) Okay, when I run that from the command line, I get this: Traceback (most recent call last): File "main.py", line 29, in <module> plist = plistlib.readPlist(os.path.join(dirname, d, 'info.plist')) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 78, in readPlist rootObject = p.parse(pathOrFile) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 406, in parse parser.ParseFile(fileobj) xml.parsers.expat.ExpatError: no element found: line 1, column 0 Hope that's helpful. Try this version : https://github.com/jmjeong/alfred-extension/blob/master/managealfredextension/ManageAlfredExtension.alfredworkflow Edited March 29, 2013 by jmjeong
CarlosNZ Posted March 29, 2013 Posted March 29, 2013 Try this version : https://github.com/jmjeong/alfred-extension/blob/master/managealfredextension/ManageAlfredExtension.alfredworkflow Working now. Cheers.
ramiro.araujo Posted March 29, 2013 Posted March 29, 2013 If you download the new version, you can launch the selected extension with shift modifier. Great work!! Thanks!
andy Posted March 29, 2013 Posted March 29, 2013 Awesome, Useful when you have a lot of workflows installed. Thanks!
FiXER Posted March 31, 2013 Posted March 31, 2013 Hi, it's not working for me. I edited the export.json file to this: { "workflow-export" : {"directory" : "~/Desktop", "enable": true}, "source-export": {"directory" : "~/Desktop", "enable": false} } Export always fail and it also created folder src in ~/Downloads. Am I doing something wrong? Thanks.
jmjeong Posted April 1, 2013 Author Posted April 1, 2013 (edited) Hi, it's not working for me. I edited the export.json file to this: { "workflow-export" : {"directory" : "~/Desktop", "enable": true}, "source-export": {"directory" : "~/Desktop", "enable": false} } Export always fail and it also created folder src in ~/Downloads. Am I doing something wrong? Thanks. I tried it in Battery.alfredworkflow, but I can't find any problem about export function. Did you tried the new version? You can the latest version from https://github.com/jmjeong/alfred-extension/tree/master/managealfredextension FYI, export.json file should be located in extension directory where you want to export such as "/user.workflow.DD0D36FD-8588-4FFE-8FC6-XXXXXXX". Edited April 1, 2013 by jmjeong
Domenic Posted April 1, 2013 Posted April 1, 2013 (edited) If i try to open a workflow in the terminal it says the folder doesn´t exist: DS-iMac:~ DS$ open -a Terminal /Volumes/Macintosh HD 2/Dropbox/Alfred.alfredpreferences/workflows/user.workflow.CC24CD39-4B60-4456-98E0-6B364329EEB0 The files /Volumes/Macintosh, /Users/DS/HD, and /Users/DS/2/Dropbox/Alfred.alfredpreferences/workflows/user.workflow.CC24CD39-4B60-4456-98E0-6B364329EEB0 do not exist. DS-iMac:~ DS$ I think that´s because of the spaces. If I paste the path like this: cd /Volumes/Macintosh\ HD\ 2/Dropbox/Alfred.alfredpreferences/workflows/user.workflow.CC24CD39-4B60-4456-98E0-6B364329EEB0 It works. Could you possibly change this in your workflow? Would be great!I like this workflow very much! Domenic edit: [...] I'm not a developer and this tool has HUGE potential in my opinion. The ability to open Alfred Preferences focused on that workflows, [...] That would be awesome! offtopic: Is it possible to edit a post and quote someone inside that edit?(with name, date, time) Edited April 1, 2013 by Domenic
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now