Windows Mac transfer problem #1 : file saving and locking

If I open a file in my Dropbox on the Windows side, I get the .rhl file lock file showing up, and if I try to open the same file on any other Windows-based machine, it tells me the file is read-only. All is well.

However, if I open the file on a Mac (while the file is still open on a Windows machine), I get no read-only indication in the title bar (or any other warning). I then try to save the file - which I shouldn’t be able to do, but the Mac lets me hit Save anyway, which results in first the file not syncing in Dropbox, then after a few minutes another file being created in Dropbox with a “conflicted copy…” suffix after the name.

This should not be happening, MacRhino should first tell me the file is read-only and just offer to “Save as” like Windows does…

By the way, I have also had to turn off autosaving system-wide on the Mac because of Rhino. I create demo files for students with some elements already in the file, then I do the demos using those and the students follow along. At the end of the demo, either I save the file under another name as a WIP (if we are going to continue later), or just close without saving in order to keep my demo file in its original state.

However, if I work on the Mac side, with autosave/versions on, it is constantly saving over my demo file, so I always have to make sure I work on a copy of the file, which is a pain…

–Mitch

not sure about the permissions while working simultaneously on the same file in osx and windows… but some other stuff:

how did you turn off autosaving? i really don’t think you can… i assume you mean you’ve set System Preferences> General> ‘Ask to keep changes when closing documents’ to yes… right?

but do this while having that pref enabled:
quit rhino… go to the folder user/ Library/ Autosave Information
(it may or may not be empty at this point depending on what else you’re doing)…

launch rhino and draw a box… notice the autosave folder gets a new document titled Unsaved Rhinoceros Document.3dm

you see- autosave is still working and in the event of a crash, you’ll have to opportunity to recover this file upon re-launching rhino even though you’ve never saved it.

to see autosave working on an already saved file in which the autosave info is being contained within the .3dm itself instead of the autosave folder, you can do this–
say you have a .3dm which is 10MB in size (right-click → get info)… open that file then select all and copy it two more times (effectively tripling the amount of data in the file)… wait 5 minutes then get info on the .3dm again… it will now be 30MB in size.
(and depending on what you do upon closing the document, it will either remain at 30MB or revert to the original 10MB)


(i have some other stuff to say on the subject(s) but i have to go do something else for a few hours… i’ll add some more later)

some other things… in no particular order but related to what you’ve said…


as you can see with the example of how autosave works by saving to the open file, that means a file in your dropbox folder is going to be uploading itself every time autosave does it’s thing…

the problem (or one of the problems) with that is-- as i understand, osx autosave only saves new data which has been added to the file… or, if i have a 5MB file which i’ve drawn a new circle in, autosave won’t re-save the whole 5MB file plus the circle… it only saves the circle which has been added… (again, this is how i understand it and an example of why i don’t like using autosaves which don’t work like this… sketchup autosave, for instance, will resave the entire file and everything in it every time it updates… that is also what happens with dropbox… if you’re working on a 10MB .3dm via your dropbox folder, autosave with may add 100KB worth of data to a file but dropbox will now re-upload the entire 10.1MB file…
(in other words, if you’re working on a decent size file via the dropbox folder and your upload speed isn’t super fast, dropbox will constantly be uploading throughout your drawing session)

anyway, maybe at this point, it’s not too good to work on rhino files which are in an auto-updating dropbox folder… probably better if you pause dropbox while working on a .3dm or manually controlling when the file syncs… or what i do is copy/drag (option key + drag) the file to the desktop, work on it, drag it back to dropbox when finished… (but that’s because a lot of the time i’m using phone tethered internet and this avoids unnecessary bandwidth use)


if you want ‘Save As’ in mavericks, go to the file menu and push/hold the option key… you’ll see the ‘duplicate’ item change to ‘save as’… or:
Shift-S → SAVE (which is also used to save a version snapshot)
Cmmd-Shift-S → DUPLICATE
opt-cmmd-shift-S → SAVE AS

however, using ‘Save As’ expecting past conventions (open a saved .3dm, do some stuff, Save As, original file is left unchanged, and a new file with the changes is saved) will not work out right…

to get similar results now on mac, the trick is to do the Save As when you first open the file instead of waiting til the end… that will leave the original file untouched then a new working file which is storing the autosaves & versions as you go forward…

again, autosave and versions is still working regardless of the system pref mentioned earlier… if you want to do SaveAs’s and you can get in the habit of doing them first, i think it’s better to have that pref set to off… because you won’t need it anymore and the questions in the dialog become unnecessary… (because if you ‘revert’ at this point, you’ll end up with two identical files with different names… SaveAs has already given you the untouched original plus a new file with a new name.

[another workaround to the behavior you’re seeking which doesn’t require duplicating the file is to open the file via rhino’s ‘New Using Template’ dialog (shift-cmmd-N)… that may still be as annoying as duplicating but it will allow you to keep the original file untouched then you’ll get a SaveAs dialog at the end in the same way you would upon trying to close a fresh/empty .3dm


i’ll probably add another thing or two later :wink:

oh… also. you could always just use Versions as intended to deal with this and keep everything in one file…

just have osx automatically save the file as you go… if at any point you want to go back to the original state of the demo file then File->Revert To and browse to the date/time when you first made the demo then Restore…

if you restore, the WIP you were working on will still be stored as a version… so, for example, you can have your base demo file then work with it in one direction, then restore to the original, then work the file in a different direction… and both directions as well as the original will all be contained and available within that single file… cmmd-S anytime you want to manually create a version snapshot…

of note-- if you email the file (or dropbox it etc.), only the current state of the drawing will be sent (i.e.- somebody can’t download a .3dm of yours then go back through all the versions)

(another sorta unrelated thing to note but can come in handy at times is when you’re in the Revert dialogs, you can navigate the models, select geometry, and copy (cmmdC) geometry… you can then go to any other version (or even another file) and paste it… this comes in pretty handy in certain drawing scenarios)

[*note-- some of this stuff was causing rhino to crash in a few of the more recent builds… the last few releases seem to have it fixed… there’s still a slight problem in that the sidebars get funky upon doing a restore… for instance, i have my left side toolbar at two icons wide… upon restoring, there’s only one row of icons and i have to readjust it back to two…]

Yeah, unfortunately, all that sounds far too complicated for my tiny brain just to work around not wanting the file to be saved… I wonder if the solution isn’t just to make the demo file read-only…

Oh, wow… Nope, that doesn’t work either, Mac simply ignores the read-only designation of the file and overwrites it… Nice…

–Mitch

you can’t make it not save.

you can either discard the saves upon closing the file or change which file the saves are occurring in.

Yeah… But the file locking system should work between systems IMO. So when you(it) tries ot save a locked file it asks to save under another name…

–Mitch

hmm… there is a concept of locking a file in osx… changing to read only is one way to do it (but you’re saying that doesn’t work for you? how did you change to read only?)
also, files will lock if they sit unopened for two weeks…

with a locked file, you’ll get this in rhino:

that said, i don’t know how locked or read-only files work in windows or how well that designation transfers across systems.