zhaowu Posted October 18, 2013 Author Share Posted October 18, 2013 It seems to be a Ruby error (I'm using 10.9 GM). This is the error when running from command line: /usr/bin/ruby /Users/martin/Dropbox/Alfred_v2/Alfred.alfredpreferences/workflows/user.workflow.FD7614C1-3388-4F55-885A-5C04C0B50D3F/instant.rb test /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require': cannot load such file -- alfred (LoadError) from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require' from /Users/martin/Dropbox/Alfred_v2/Alfred.alfredpreferences/workflows/user.workflow.FD7614C1-3388-4F55-885A-5C04C0B50D3F/instant.rb:20:in `<main>' Any ideas on how to fix it? Thanks run `rake bundle:install` in the workflow folder. 10.9 upgraded the ruby version. Link to comment
Martin Posted October 18, 2013 Share Posted October 18, 2013 run `rake bundle:install` in the workflow folder. 10.9 upgraded the ruby version. Thanks for helping out. Running that command, gives me this error: /Users/martin/Dropbox/Alfred_v2/Alfred.alfredpreferences/workflows/user.workflow.FD7614C1-3388-4F55-885A-5C04C0B50D3F on iMac.local: rake bundle:install --trace rake aborted! No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb, Rakefile.rb) /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:598:in `raw_load_rakefile' /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:89:in `block in load_rakefile' /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:160:in `standard_exception_handling' /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:88:in `load_rakefile' /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:72:in `block in run' /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:160:in `standard_exception_handling' /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rake/application.rb:70:in `run' /usr/bin/rake:37:in `<main>' Link to comment
zhaowu Posted October 18, 2013 Author Share Posted October 18, 2013 (edited) Sorry, I forget the package does not include the Rakefile. You need to Delete the existing workflow from Alfred 2, clone the repo from https://github.com/zhaocai/alfred2-google-workflow to anywhere you like. Run `rake bundle:install && rake install` in the folder. Edited October 18, 2013 by zhaowu Link to comment
Martin Posted October 19, 2013 Share Posted October 19, 2013 Sorry, I forget the package does not include the Rakefile. You need to Delete the existing workflow from Alfred 2, clone the repo from https://github.com/zhaocai/alfred2-google-workflow to anywhere you like. Run `rake bundle:install && rake install` in the folder. OK, so I did that, but now there's a new error /Users/martin/Downloads/alfred2-google-workflow on iMac.local: rake bundle:install && rake install cd google bundle install --standalone --clean fail to install gems (status = 127) ln -sf /Users/martin/Downloads/alfred2-google-workflow/google /Users/martin/Library/Application Support/Alfred 2/Alfred.alfredpreferences/workflows/me.zhaowu.google Link to comment
zhaowu Posted October 20, 2013 Author Share Posted October 20, 2013 OK, so I did that, but now there's a new error /Users/martin/Downloads/alfred2-google-workflow on iMac.local: rake bundle:install && rake install cd google bundle install --standalone --clean fail to install gems (status = 127) ln -sf /Users/martin/Downloads/alfred2-google-workflow/google /Users/martin/Library/Application Support/Alfred 2/Alfred.alfredpreferences/workflows/me.zhaowu.google try to download the updated Google.alfredworkflow and import to Alfred 2 Link to comment
AlfredUserNumber8 Posted October 23, 2013 Share Posted October 23, 2013 (edited) Strange. After installing Mavericks, site search etc don't work Edited October 23, 2013 by Barrierfreeman Link to comment
Martin Posted October 24, 2013 Share Posted October 24, 2013 try to download the updated Google.alfredworkflow and import to Alfred 2 Thanks a lot, this new version works in Mavericks with "gi" search What did you have to change to fix it? Then I can tell other workflow developers how to make it work. Link to comment
zhaowu Posted October 24, 2013 Author Share Posted October 24, 2013 The reason for this issue is locale and related encoding issue: http://www.alfredfor...le-in-maverick/ Thanks a lot, this new version works in Mavericks with "gi" search What did you have to change to fix it? Then I can tell other workflow developers how to make it work. Link to comment
zhaowu Posted October 24, 2013 Author Share Posted October 24, 2013 Update to support Maverick, please give it a try. Link to comment
AlfredUserNumber8 Posted October 24, 2013 Share Posted October 24, 2013 Works again. Excellent stuff, zhaowu. The only thing which seems odd, is the option to show search results in browser, has moved from its usual position at #1 to #3 in the list: Link to comment
zhaowu Posted October 25, 2013 Author Share Posted October 25, 2013 did it on purpose. Trust google to show up the best results. If I want to search in the browser, hit ⌘ + 3. Works again. Excellent stuff, zhaowu. The only thing which seems odd, is the option to show search results in browser, has moved from its usual position at #1 to #3 in the list: Link to comment
AlfredUserNumber8 Posted October 25, 2013 Share Posted October 25, 2013 Ah, I thought you may have. Many thanks again for getting it working again. It's my most used extension! Link to comment
glortho Posted October 25, 2013 Share Posted October 25, 2013 (edited) On Mac OS 10.8.5 only "g" works. Everything else reverts to default searches as soon as you type a query. (Works great on OS 10.9, however.) Edited October 25, 2013 by glortho Link to comment
zhaowu Posted October 26, 2013 Author Share Posted October 26, 2013 Can you run `LANG=en_US.UTF-8 /usr/bin/ruby ./instant.rb test` in the Terminal, give me the output and ~/Library/Logs/Alfred-Workflow.log? I do not have 10.8 installed to test. Thanks. On Mac OS 10.8.5 only "g" works. Everything else reverts to default searches as soon as you type a query. (Works great on OS 10.9, however.) Link to comment
glortho Posted October 28, 2013 Share Posted October 28, 2013 Where is ./instant.rb supposed to be? I also do not have any kind of Alfred log in ~/Library/Logs. Link to comment
zhaowu Posted October 28, 2013 Author Share Posted October 28, 2013 right click and show in finder. Check the screenshot: http://d.pr/i/jjnm+ Link to comment
glortho Posted October 28, 2013 Share Posted October 28, 2013 (edited) Got it. This is output: dyld: lazy symbol binding failed: Symbol not found: ___memccpy_chk Referenced from: /<removed>/Alfred 2/Alfred.alfredpreferences/workflows/user.workflow.FCBDF848-A9CC-4576-9686-1D3197B1273C/bundle/ruby/1.8/gems/json-1.8.1/lib/json/ext/generator.bundle Expected in: /usr/lib/libSystem.B.dylib dyld: Symbol not found: ___memccpy_chk Referenced from: /<removed>/Alfred 2/Alfred.alfredpreferences/workflows/user.workflow.FCBDF848-A9CC-4576-9686-1D3197B1273C/bundle/ruby/1.8/gems/json-1.8.1/lib/json/ext/generator.bundle Expected in: /usr/lib/libSystem.B.dylib [1] 91370 trace trap LANG=en_US.UTF-8 /<removed>/ruby ./instant.rb test Edited October 28, 2013 by glortho Link to comment
zhaowu Posted October 29, 2013 Author Share Posted October 29, 2013 json compiled from osx 10.9 does not work in osx 10.8. need to download the source and update the gem locally. Link to comment
Easytiger Posted November 16, 2013 Share Posted November 16, 2013 Hi, your workflow is great! Just want to change the gi search to German. I just changed the .com to .de, now it says in the instant.rb "arg => URI.escape("http://www.google.de/search?as_q=#{query}&lr=lang_")" Is this correct? Anything else that I need to change? It unfortunately does not work at the moment, only provides outputs for the english google. Any help would be very much appreciated. Thanks! Link to comment
zhaowu Posted November 18, 2013 Author Share Posted November 18, 2013 (edited) you need to also change the ` GOOGLE_HOST = 'www.google.com'` in the lib/google_suggest.rb. I will try to find sometime to make this configurable. Edited November 18, 2013 by zhaowu Link to comment
Easytiger Posted November 19, 2013 Share Posted November 19, 2013 Thanks zhaowu, I think this works. Great! Would be great if there is a way to make this configurable. Cheers! Link to comment
xilopaint Posted January 24, 2014 Share Posted January 24, 2014 I'm sorry, but I really don't know how to configure the workflow for getting suggestions from google.com.br. Could you give me a hand? Link to comment
rspike12 Posted January 30, 2014 Share Posted January 30, 2014 I'm sorry, but I really don't know how to configure the workflow for getting suggestions from google.com.br. Could you give me a hand? same problem here....google.it I didn't understand how to change the file to have search suggestions in my language Link to comment
skyeyjay Posted June 14, 2014 Share Posted June 14, 2014 Hi, How can i know which version that I'm using? (Latest Version or not?) And how to update it? *Thanks for very useful Workflow. Link to comment
madvas Posted April 26, 2015 Share Posted April 26, 2015 Awesome workflow! Many thanks. Is there a way to set 'g' command as fallback results in Alfred? When I go Alfred -> Default Results -> Setup fallback results -> '+' -> Workflow trigger, there's not this workflow Link to comment
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