Author Topic: Version Control Plugin  (Read 8194 times)

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Version Control Plugin
« on: August 17, 2011, 01:20:27 pm »
Hi All,

This is an old project and now I got some free time, so I'm back to it. My idea is the implement a Visual SourceSafe Plugin for C::B.

I'm still in the conceptual stage and I have a question for the C::B developers:

- What's the best way to deal with the File States within a plugin?

I've seen that the enum FileVisualState defines states for version control (vc) and that it can be set using the SetFileState() method from the ProjectFile class, but I still have two questions:

- What's the cleanest way to get a pointer to the project manager or the actual project?
- Even if I set the File State in my plugin, it gets overwritten by the cbEditor::SetModified() method (cbeditor.cpp, line 850) when a file read-only property is changed (I've tried it and it really does).

Any help is very much appreciated,
daniloz

zabzonk

  • Guest
Re: Version Control Plugin
« Reply #1 on: August 17, 2011, 03:50:47 pm »
> implement a Visual SourceSafe Plugin for C::B

I though SourceSafe was dead? Haven't MS killed it off? and anyway, I can't imagine any CB users would want to use it.

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Re: Version Control Plugin
« Reply #2 on: August 17, 2011, 04:17:13 pm »
> implement a Visual SourceSafe Plugin for C::B

I though SourceSafe was dead? Haven't MS killed it off? and anyway, I can't imagine any CB users would want to use it.

Not quite dead on our company... still using it...
Well, I want to use it. I do DSP programming and the Analog Devices IDE is just useless, so I use C::B, but our vcs is SourceSafe, so the idea... ;-)

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Version Control Plugin
« Reply #3 on: August 17, 2011, 04:41:11 pm »
I though SourceSafe was dead? Haven't MS killed it off? and anyway, I can't imagine any CB users would want to use it.
IMHO a sourcesafe plugin exists already... :shock:
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Re: Version Control Plugin
« Reply #4 on: August 17, 2011, 04:45:09 pm »
IMHO a sourcesafe plugin exists already... :shock:

Hmmm... I completely missed that... where?  :shock: please!  :P

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Version Control Plugin
« Reply #5 on: August 17, 2011, 05:31:47 pm »
Hmmm... I completely missed that... where?  :shock: please!  :P
Ok - I checked back and shame on me! :oops:
It's a ClearCase plugin, not SourceSafe. So please ignore what I've said. :oops: :oops: :oops:
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Re: Version Control Plugin
« Reply #6 on: August 19, 2011, 01:27:46 pm »
Back to my original question:
- What's the best way to deal with the File States within a plugin?

I've seen that the enum FileVisualState defines states for version control (vc) and that it can be set using the SetFileState() method from the ProjectFile class, but I still have two questions:

- What's the cleanest way to get a pointer to the project manager or the actual project?
- Even if I set the File State in my plugin, it gets overwritten by the cbEditor::SetModified() method (cbeditor.cpp, line 850) when a file read-only property is changed (I've tried it and it really does).

Anyone? I don't know the structure of codeblock so well and the only way I found to do it was as described above, but the File Status get overwritten...

Or maybe I'm posting on the wrong place here? :-o