Jump to content

Unable to overwrite read-only files with PlasticSCM in VS2013


alexidr

Recommended Posts

Hey fellows,

 

I have started using PlasticSCM and installed the plug-in for Visual Studio 2013 (guess the same would happen for other versions as well).

PlasticSCM became the current source control plug-in in VS settings, but for one of my projects I continue using P4 (without VS integration) and as we know it makes files read-only when you submit. I'm used to simply overwrite files when I make changes, but now when I try to save a modified file it shows different Save As dialog and you can't overwrite until you remove the read-only flag. That's very annoying. I tried to disable source control at all and it worked, I tried to enable different source control plug-ins (VisualSVN for instance) and it also worked. So it seems that PlasticSCM hooks the files management and doesn't allow me to overwrite my read-only files... 

 

Any ideas, guys?

Link to comment
Share on other sites

Hey,

 

No... it wasn't enabled. You don't understand. I use P4 for one of my projects and it makes my files read-only.

But PlasticSCM is enabled as a source control plug-in in Options -> Source Control -> Plug-in Selection in VS settings.

 

So I guess PlasticSCM tries to forbid me to overwrite read-only files... Normally in VS when you try to save read-only file modified in memory, you're asked if you want to overwrite, cancel changes or save as different file, but with PlasticSCM plug-in VS is no longer asking and show me a Save As dialog instead.

Link to comment
Share on other sites

  • 3 weeks later...

Hi,

 

I´m performing a more detailed test. Are you using the "Plastic SCC plugin" or the "VS 2013 package"? 

 

Regards,

Carlos

 

Hi,

 

I'm not sure what you mean by VS 2013 package. I just got Plastic SCM basic installer and run through the installation process. It installed client and plugin for VS. Plastic SCM became the current source control plugin in VS settings and that's basically it. You don't even need to add you project to source control to see that "bug" happens.

 

It will be great if you could fix this, because it's pretty annoying if you're using VS not only with the Plastic source control... To workaround this I just disabled the plugin in VS and use the client instead every time I need to work with Plastic.

Link to comment
Share on other sites

Hi,

 

Yes this is the VS integration package (the isntaller also has a SCC plugin that allows you to perform the basic operations).  I tryed the next steps:

 

- Install Plastic SCM and VS 2013 plugin.

- Select Plastic SCM as Source control, create a new project and add it to source control.

- Drive to the workspace path and set some files as "Read only".

- In the VS project explorer I open the file, modify and save it.

- Checkin the changes.

 

Not sure if I am missing any step or the P4 client performs any operation that I am missing.  What Plastic version are you using?

 

Reagrds,

Carlos

Link to comment
Share on other sites

Hi,

 

Thank you for your patience.

 

The problem I'm talking about only occurs if you don't add your project to source control. As I mentioned before, one of my projects uses Perforce without VS integration so I didn't add this project to source control (but Visual Studio itself has Plastic SCM set up in its settings).

 

Just to be clear, try next steps:

 

- Install Plastic SCM and VS 2013 plugin.

- Select Plastic SCM as Source control, create a new project, BUT DON'T add it to source control.

- Drive to the workspace path and set some files as "Read only".

- In the VS project explorer open the file, modify and try to save it. Instead of a normal VS dialog for pending changes you'll see the Save As dialog, that is actually a problem...

 

I have tried setting Visual SVN plugin and it worked as expected, so it seems that only Plastic SCM has this problem.

 

Thank you in advance, I hope now I'm clear with my problem :)

Link to comment
Share on other sites

Hi,

 

But if you don´t add it to source control, the Plastic plugin is not performing any operation. I mean, although you install the plugin, if you don´t bind the project to Plastic source control, VS behavior shouldn´t change.

 

Anyway, if you are not adding the project to source control using the plugin, why did you install the plugin?

 

 

PD: Not sure if you are aware that you are able to use Plastic in a transparent way. You don´t need to install the VS plugin. You can just perform the changes in your VS solution, and then commit the changes using the Plastic GUI (no plugin interaction). 

 

Regards,

Carlos

Link to comment
Share on other sites

Hi,

 

But if you don´t add it to source control, the Plastic plugin is not performing any operation. I mean, although you install the plugin, if you don´t bind the project to Plastic source control, VS behavior shouldn´t change.

 

Anyway, if you are not adding the project to source control using the plugin, why did you install the plugin?

 

 

PD: Not sure if you are aware that you are able to use Plastic in a transparent way. You don´t need to install the VS plugin. You can just perform the changes in your VS solution, and then commit the changes using the Plastic GUI (no plugin interaction). 

 

Regards,

Carlos

 

I thought the same, it shouldn't perform any action. But in fact, if you install the plugin and set it as default in settings, it changes VS's behavior as I said before, you can just try it yourself. Also I tested the same with Visual SVN and it worked. Seems only Plastic has some bad impact...

 

To answer why I need it. As I said, I'm working on multiple projects. One of them uses Perforce (without plugin) and another Plastic SCM (with plugin). Since VS stores source control setting as a global settings, you can't make Plastic plugin enabled for one project and disabled for another. But, as I don't use Perforce plugin anyway, I installed Plastic SCM and made it default. So I got VS set up for using Plastic, one project's added to Plastic's source control (works fine), and one that wasn't added to source control (doesn't work fine).

 

I know I can use Plastic client and that's what I actually do now because of this issue. I just wanted you guys to know that it happens and it's better to be fixed... 

 

Do I make myself clear this time...?

Link to comment
Share on other sites

Hi,

 

Yes! I finally reproduced the issue. We are perfoming VS tests this week, so hopefully we can fix this problem.

 

Regards,

Carlos

 

Hi,

 

Thank you, Carlos. I hope to see something about it in the next release notes ;) Anyway, you guys're doing a great job, really love Plastic SCM !

Link to comment
Share on other sites

  • 3 weeks later...

Archived

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

×
×
  • Create New...