lhl / chrome-ssb-osx

Simple script for making Chrome-based SSBs (site specific browsers)
147 stars 29 forks source link

Opening PDF (Symlink vs. Hardlink) #8

Closed gzuercher closed 11 years ago

gzuercher commented 11 years ago

Hi,

when i create the ssb for a website (webmail), i cannot open PDF files. This is due to the symlink to the Versions directory (/Applications/Google Chrome.app/Contents/Versions). When i replace it with a hardlink everything works fine. Since hardlinking of folders in OSX is crippled, you need more manual stuff:

http://stackoverflow.com/questions/1432540/creating-directory-hard-links-in-macos-x or http://www.bram.us/2013/02/08/os-x-hardlink/

Would be nice if you could include this in the script :)

kind regards

Guy

lhl commented 11 years ago

Yikes and yikes. So thanks for reporting this. I'll add the note for now in the readme, however I think for the general use case, unless other people need to use it I'll leave the hard links out - it's too easy to shoot yourself in the foot (finding all the hardlinks pointing to a file, what happens w/ upgrades, or across volume boundaries)

jeffpoulton commented 11 years ago

I followed the steps using the hardlink script and it worked perfectly? Problem: it only works with one app! When I try to follow the exact same steps (outlined here on my blog, I get:

$> hardlink: file exists

Has anybody else experienced this? I'll file an issue on the hardlink repo, but would love to know if others have had this issue.

deanmalmgren commented 11 years ago

@jeffpoulton I did not use the hardlink script but I did create two apps (one for gmail and one for gcal) and I had a similar error when creating the second app:

ln: /path/to/GCal.app/Contents/Versions/Versions: File exists

When I look in the /Applications/Google Chrome/Contents/Versions directory, I notice that there is now a soft link called Versions that points to the root of the directory with a timestamp from today:

[hal-9000 generated]$ ls -l /Applications/Google\ Chrome.app/Contents/Versions/
drwxrwxr-x  7 xxxx  admin   238B Aug 24 09:31 29.0.1547.62
drwxrwxr-x  7 xxxx  admin   238B Aug 30 15:36 29.0.1547.65
lrwxr-xr-x  1 xxxx  admin    49B Sep 16 06:26 Versions -> /Applications/Google Chrome.app/Contents/Versions
deanmalmgren commented 11 years ago

I'm not sure how or why that versions directory appeared. It was clearly created today but I haven't been able to reproduce it when I create other SSBs. My issue may be totally unrelated to @jeffpoulton's; sorry for the confusion...

lhl commented 11 years ago

@aerickson's pull should fix the PDF issue

lhl commented 11 years ago

Just an FYI: reverted that pull (caused regression w/ being able to alt-tab/show as a separate app) but new versions of Chrome appear to have addressed the issue.

jeffpoulton commented 10 years ago

Is it just me or are other people still experiencing the PDF bug on the latest version of chrome-ssb-osx and Chrome?