Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am running Photoshop CS2 under Ubuntu 10.10 with Wine 1.3.23. I would like to be able to associate various file types with Photoshop. I'd previously used this script:

#!/bin/sh
QUICKPARLOCATION="c:\\Program Files\\Adobe\\Adobe Photoshop CS2\\Photoshop.exe"
PARAM=`winepath -w "$*"`
wine "$QUICKPARLOCATION" "$PARAM"
exit 0

If I make this script be the customer command that's tied to "Open With," Photoshop launches, but doesn't appear to be properly passing the file name, so that file doesn't open. I'd had this working previously under earlier versions of Ubuntu and wine.

P.S. please no commentary on using GIMP or other Photoshop alternatives

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

The custom command should be possible in one string without needing a script.

The following custom command will launch photoshop via wine:

wine "c:\\program files\\adobe\\adobe photoshop cs2\\photoshop.exe" \"z:%f\"

The key part is the last part \"z:%f\

  • %f passes the filename selected.
  • Prefixing z: does the same as winepath -w for a file which you double-click.
share|improve this answer
    
I initially tried your suggestion and it didn't work. I then took a look at my wine config and see that I'd previously mapped the "Z" drive to something else. Once I removed the mapping, all was good... this has been bugging me for a while, so thanks very much for your input. –  Kendor Jul 16 '11 at 23:47
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.