Jump to content

schoeps

Member
  • Posts

    53
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by schoeps

  1. Sure. I guess Yosemite stores paths differently.... if 'pdf' in source: if not 'http' in source: clean_file = urllib.unquote(source) _file = clean_file.replace('file://', '') if os.path.isfile(_file): subprocess.Popen( ['open', _file], shell=False, stdout=subprocess.PIPE)
  2. I had problems with opening attachments on Yosemite. However, it could be easily fixed by replacing line 96 of "actions.py" by _file = clean_file.replace('file://', '') Maybe this helps someone...
  3. Thanks. I deleted my bibdesk cache and recreated it; now it's working. Your parsing seems to be more sensible than my approach (but it seems to be faster too...). the icons are really nice and some meanings are obvious but some are not so clear. Furthermore there are probably more types than icons ("electronic", "misc" and unpublished",...). I don't know about others but I use all of them. However it's probably easy to modify your workflow to do that. yes, see above. with bibdesk it's not too difficult as you might have seen. Alternatives are other external parsing engines (bibtex2html...) but this seemed to be overkill for me.
  4. Problem seems to be solved I had to convert from URL encoding. Now I use PHP for that set thePOSIXfile to do shell script "php -r \"echo rawurldecode('" & theURL & "');\"" Please test it: BibDesk_Search_beta.alfredworkflow
  5. Hi stephen, first, your workflow looks great and judging on its complexity it seems that it requires more time than I can afford for bibsearch. Hence I am very pragmatic and once your feature set is greater than bibsearch's, I will most probably stop maintaining bibsearch. In particular because my time does hardly allow it. Let me give some general remarks: it would be nice to display the bibtype because there might be preprints and papers with the same name, date and authors in your database users asked me to display the year before the authors list because it might be very long (e.g. in medicine or physics, ..) and then the date information is not shown I think for many users it is convenient to copy a complete citation string of a publication, e.g. if they have to work with MS Word and they want to add a single reference in some footnote. This is ongoing work in bibsearch. However, you can take whatever I have added there. However, I tried it today and I got the following error Starting debug for 'BibQuery' [ERROR: alfred.workflow.input.scriptfilter] Code 1: 09:44:22 workflow.py:1199 ERROR Bad file header Traceback (most recent call last): File "/Users/xxx/Library/Application Support/Alfred 2/Alfred.alfredpreferences/workflows/user.workflow.CF861A51-8CB7-4408-93CA-D51684C77953/workflow/workflow.py", line 1197, in run func(self) File "bibquery.py", line 442, in main filter(queries, scope, wf) File "bibquery.py", line 420, in filter simple_filter(query, scope, wf) File "bibquery.py", line 310, in simple_filter data = read_cachedir() File "bibquery.py", line 83, in read_cachedir bib_data = ccl_bplist.load(_file) File "/Users/xxx/Library/Application Support/Alfred 2/Alfred.alfredpreferences/workflows/user.workflow.CF861A51-8CB7-4408-93CA-D51684C77953/ccl_bplist.py", line 258, in load raise BplistError("Bad file header") BplistError: Bad file header
  6. That is good news! Now, we know that spaces in file names seem to be the bad guys (I would never have found this issue because I use the bibkeys as filenames). I will have look to it!
  7. Can you try the workflow with the latest pre-release alfred? Thanks!
  8. Thanks! I have created a new beta version (BibDesk_Search_beta.alfredworkflow) that now includes its own Bibdesk template. Can you please try it? I have also corrected the readme: You can use the following actions: - [return] to open in Bibdesk - [cmd]+[return] to reveal attached pdf in finder - [alt]+[return] to open attached pdf in your favorite viewer - [shift]+[return] to copy the citekey to clipboard - [ctrl]+[return] to copy a citation string
  9. As you may have guessed, the scripts are working fine on my computer. Thus we have to debug it together... I have uploaded a debug build here: BibDesk_Search_debug.alfredworkflow It should show dialogs with the path to the entry selected in Alfred. Let's have a look at the more difficult case, i.e., what happens if you press ^↩. For this we analyze the Applescript. Can you copy the following into the Applescript editor and adapt q to contain the path to your bdskfile? What happens if you run it? set q to "/Users/????/Library/Caches/Metadata/edu.ucsd.cs.mmccrack.bibdesk/????.bdskcache" --remember active app tell application "System Events" set activeApp to name of first application process whose frontmost is true set process_bid to get the bundle identifier of process activeApp set activeApp to file of (application processes where bundle identifier is process_bid) set activeApp to activeApp as string end tell -- check whether BibDesk is ready tell application "BibDesk" activate if (count of documents) = 0 then beep display dialog "Please open your BibDesk database" buttons {"OK"} default button 1 return end if end tell tell document 1 of application "BibDesk" set bibkey to do shell script "mdls -name net_sourceforge_bibdesk_citekey '" & q & "'| cut -d'\"' -f 2" set thePub to get publications whose cite key is bibkey set theResult to (templated text using "abbrvTemplate" for thePub) end tell tell application activeApp to activate return theResult
  10. There is a readme for each workflow, you can access it by double-clicking on the workflow icon within Alfred's preferences. Your question is hopefully answered there:
  11. Just to let you know, same problem occurred here after the update. However deleting the history helped.
  12. I have changed the latest workflow from beta to an official version 2.1: BibDesk_Search.alfredworkflow .
  13. I have played around with templated rich text in the applescript to preserve formatting but this seems not to work. However, I added your changes to "Beta 2": BibDesk_Search_beta2.alfredworkflow. Thanks! I will use this version a few more days and then update the main download link.
  14. I have tried but latexit does not support Applescript natively. There are sme workaround but before I can copy the image I need to determine when the rendering is done and this does not work. It seems impossible. Sorry.
  15. Great idea. I have set up a beta version. I hope that I have introduced no new bugs: https://bitbucket.org/schoeps/alfred/downloads/BibDesk_Search_beta.alfredworkflow If you press [CTRL]+[Enter] Alfred copies the publication string to the clipboard. I use the Bibdesk template "abbrvTemplate" for now but this can be changed easily. Please give feedback.
  16. Hi atomkraft, is the problem still present?
  17. Hi, I have uploaded version 1.2. It should fix problems with firewire showing up as vpn.
  18. I have updated the workflow to version 2.0; prior versions were very slow under Mac OS 10.9. It should be much faster now (be aware: searching becomes slower with each keyword). Please report any problems!
  19. The output is perfect and since the main work of the plugin is done exactly in this php script I is difficult to debug beyond this point. However, do you use Mavericks? I realized that search results come sometimes with some delay. I will try to find out why...
  20. You have a ".bib"-file somewhere that contains your library, right? Then you need to open it with bibdesk and then save it. The reason is that Bibdesk creates .bdskcache whenever it saves a bib-file. Afterwards they should be visible to Alfred.
  21. OK, let's try to find out what the problem is: 1. what is the content of the directory ~/Library/Caches/Metadata/edu.ucsd.cs.mmccrack.bibdesk/ There should be plenty of files ("*.bdskchache"). 2. open terminal.app and go to the directory of the bibdesk plugin (you can find out the location by opening the workflow tab of the preferences, then right click on bibdesk workflow and click open in finder). Enter in terminal: php search.php author What is the output?
  22. The problem should be fixed in the latest version (1.6). I had to employ some very strange encoding tricks. Bye, Sebastian
  23. Thanks for posting. The post at open radar seems to further indicate that there is a bug in Mavericks. I am afraid that we need to wait since I am not aware of any other way to start the VPN connection Sorry!
  24. I do not have mavericks hence debugging is difficult for me but since you must be a developer to get 10.9, you can probably help me Just run the following code in the applescript editor (of course replace VPNCONNECTION with the correct string as given in the system preferences) and see what is happening... tell application "System Events" tell current location of network preferences set VPNservice to service "VPNCONNECTION" set isConnected to connected of current configuration of VPNservice if isConnected then disconnect VPNservice set output to "Disonnected" else connect VPNservice set output to "Connected" end if end tell end tell
  25. Hi, it should be fixed in 1.5, i.e., "bib xxx" searches the keys too. Maybe I will think in the future about specific keywords like "bibkey WimmerMayringerEtAl1999" to allow more precise search… well let's see Bye Seb.
×
×
  • Create New...