Jump to content

Setting for Marking *Only* Lockable Files ReadOnly


Recommended Posts

I see that there is an option to mark every file readonly after an Update/CheckIn, but is there an option I missed to mark only lockable files readonly? Since we have ways to merge non-lockable files, we do not want  mergeable source code files to require check-outs/be marked readonly. We just want the binary files that we've marked spec'd as lockable to be marked readonly.

-Doug

Link to comment
Share on other sites

Link to comment
Share on other sites

Is there a way to update the workspace after changing to the option of "Update and Checkin operations set files as read-only." to enabled?

Previous all my files were writable and after changing that options and updating, they still are.  The only thing I found that worked was deleting all the files in the workspace (after checking thing in) except for the .plastic folder and then doing another Update.

It also didn't seem to actually work with the writable.conf file that I placed in the root of my workspace. It contained:

*.cs

And all of my .cs files are now marked read-only along with all the other files.

Link to comment
Share on other sites

I think I was finally able to get this working, but the docs are a bit confusing. I was not able to get it to work by placing a writable.conf file in the root of the workspace as implied in the docs which would have been nice: 

Quote

The writable.conf and readonly.conf files can be located:

  • In the root directory of the workspace.

I'm guessing that is old? It seems that now it needs to be placed in a plastic-global-config repository inside a /repname/ or /allrepos/ sub-directory? And the contents of the file should be the extension without wildcard:

.cs

Also, I still had to delete my local repository workspace and re-create/update it to have it update the read-only flag on the files properly. Simply changing plastic-global-config:/allrepos/writable.conf and checking that in and updating the other repo did not properly update the read-only flags.

Link to comment
Share on other sites

Hi @ziflin!

the workspace root path is a valid place both the "writable.conf" and "readonly.conf". I've tested with the latest release and it works as expected.

I'm wondering if you had the following preference enabled or another writable.conf placed elsewhere, that might interfere the result.

On 7/27/2018 at 3:02 PM, ziflin said:

Also, I still had to delete my local repository workspace and re-create/update it to have it update the read-only flag on the files properly. Simply changing plastic-global-config:/allrepos/writable.conf and checking that in and updating the other repo did not properly update the read-only flags.

Yes! That's how it works. You need to clear the workspace and download everything as the flag is only written during the update operation.

Link to comment
Share on other sites

I have the "Update and Checkin operations set files as read-only" preference set and if I make a plastic-global-config repo with /allrepos/writable.conf in it then it works as state. This is the only .conf file I'm using other than an ignore.conf file in the workspace root which is also working.

If I move the writable.conf file to the root of my workspace and check that file in and then clear my workspace files (including it) and do an Update, then the read-only flag isn't set properly -- everything is marked readonly. I'm guessing that this is because I'm supposed to have the writable.conf file there before I do the update? If so, this obviously doesn't help with setting up repo/site-wide settings and it seems that the solution is to use the plastic-global-config repo for these settings.

I was mostly trying to keep the settings contained in the repo itself, but I'm guessing this isn't possible? This would just make it a bit easier to relocate to another server machine down the road without having to remember to setup the plastic-global-config repo again.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...