Unidirectional symbolic links
Hi all,
My Google-fu has come up short, and I can't find any solution to my problem. I'm looking for a way to create a unidirectional symbolic link. I use Dropbox for back-up and file/folder sharing, an excellent service, but lacks one important feature: Read-only folder sharing. My (initial) aim is to share my photos directory with my girlfriend, synced over dropbox. Currently I'm using symlinks to the dropbox folder so that it doesn't waste space, however, I have a separate folder with just our photos that's currently being shared. It's a duplication of my files, which are taking up space, both on my computer and on my dropbox. The reason I don't just share the one folder is the read-only thing. I trust her, but if something were to go wrong, I would rather her not accidentally deleting or changing my photos directly. The only way I can think of that would solve my issue with dropbox, is to find away of creating unidirectional symbolic link. A symlink which is in essence read-only in the dropbox folder, but read-write in the normal directory. So that I can make change/addition, and it syncs with the server. It then downloads on her computer via dropbox. However if she makes a change, it'll sync to the server, download the changes to my dropbox folder, which would automatically return back to the state it was before her change, then sync with the server, changing it back on hers again, etc.. I have no idea how to make such a link. Wondering if anyone did know. However I know it can be done with something like a script that triggers in response to dropbox syncing. It would probably run a diff against the folders, and if there is any difference to use rsync or simply cp etc. Thanks for any thoughts. |
Looking at the number of views vs. the lack of responses I can only guess
that people don't understand what you're asking (I don't). All links are uni-directional. That kind of makes your question moot. Unless of course you're using the wrong terminology, which is what I suspect. Maybe if you explained more about what you're doing, how you're utilising dropbox, what OS you're using, and who *she* is, and how she utilises your photos. Do you live together? Where does she sit in relation to your home network? |
TL;DR at bottom.
Quote:
She is my girlfriend. We do live together, and we usually are sharing a network, though she is on Windows 7. However I want a network independent solution, and for the files to exist on her computer, hence the use of Dropbox, as we both use it. NOTE: I will amend the original post to correct this. Quote:
For example:
I am asking if it is possible to create a link in which the data can only be updated in one of the directories.
Quote:
The machine that this would be implemented on happens to be running Mac OS X Lion, however because of the nature of symlinks, dropbox and the nature of what I am asking, the solution shouldn't depend on OS, that is why I asked without stating. Only way I can think that it would is if the symlink from, say, Arch had this ability with a flag, whereas CentOS doesn't. Just as Dropbox isn't actually important here. This (if possible) would all be happening locally. As I previously noted, I know I can use automated scripts using diff and rsync, but this would require still having two unlinked directories on my computer, which would therefore take up twice the hdd space. TL;DR All I am asking for: Is it possible to make a symlink that only allows the target to be updated via the source, and not vice-versa? |
All times are GMT -5. The time now is 05:15 PM. |