[Lazarus] Development of other revision control
Reinier Olislagers
reinierolislagers at gmail.com
Sat Apr 14 08:59:56 CEST 2012
On 13-4-2012 20:28, Dawson wrote:
> Hi ... a few more replies ...
>
> On 12/04/12 1:06 PM,
> Reinier wrote ...
>> First: a plugin and an API do not necessarily exclude each other.
>> They're independent concepts. A plugin can provide an API, and a plugin
>> can use an API. This may have been the cause of some confusion.
>>
>
> yes, my bad .. I played a little loose with my terminology. sorry.
>> lazsvnpkg is a plugin in the sense that it is an optional component (a
>> package) in Lazarus.
No worries!
>> If you want to expose SVN functionality further, and if there's any
>> need, adding an API to the component/plugin would be possible. It's just
>> that I don't directly see the use for that - perhaps for other IDE
>> component writers?
> Yes, one thing that appears to be missing is user / password control.
In the architecture I proposed you'd simply extend the SVN class (and
the git, mercurial etc classes) to add that functionality, then add
username/password management to your component. No need for an extra API.
>> If you mean what Sven deduced in his other mail: provide an API for
>> revision control systems at a lower level that an IDE plugin/package can
>> use... that's a good idea, that's certainly already partly executed by
>> separating the lazsvnpkg SVN functionality in a separate unit.
>> I'd suggest having a look at class I sent you a link for earlier to see
>> some ideas for extensions (i.e. getting current local revision number,
>> combining SVN checkout and update) that could be possible.
>>
> Yes, that is more like what I had in mind, a more generic approach which
> would allow the user to make use of the SCM method that he/she likes or
> needs to use for a given projcet. Flexibility is what I'm after here.
Glad to hear it ;)
> Ludo wrote ...
>
>>
>> What is missing is the functionnality to create a new repository from the
>> current project.
>
> I totally agree. In fact that seems to be a big problem with every gui
> implementation that I've seen so far, including the standalone
> applications. (Now, to be fair, I might not have tried all the right
> combinations, but I couldn't get things to work if I had a project
> already in a folder. If I use the command line versions I could. So I
> actually found the command line tools easier to use than the guis. Hmmm
> something seems wrong there. I want to make things as easy to use as
> possible, so that the user doesn't need to stand on their head and count
> to a million while looking at a blue moon. Just joking, but seriously, I
> think a good SCM should be fairly easy to learn how to use even for
> someone who is just beginning.
Totally agreed that this is very relevant functionality.
Functionality in stand alone Have a look at e.g. TortoiseHg (probably
TortoiseSVN), that allows you to start a new repository, then select all
your files, then add to repository.
However, this functionality need not be copied as Lazarus already knows
all source files you put in your project so the plugin should just be
able to come up with a list of them (and other files in the directories)
so you can add e.g. readme files and then create your repository.
Note: still haven't looked at the SVN component in Lazarus - guess I
just don't use SVN...
> Hans-Peter wrote ...
>
>> An API may be required when multiple CVS shall be supported at the same
>> time. Then somebody (the IDE?) has to determine which of the installed
>> packages is used by a project.
>>
>
> Yes Hans-Peter,
> I was thinking that just like you have project settings, you could have
> SCM settings on a project by project basis (somewhere ... either in a
> separate file, or in the lpi [that might be a touchy subject ... I don't
> know) that would keep track of whatever stuff the SCM doesn't know
> about. Or, the SCM module could simply look for the appropriate folder
> such as .SVN, .GIT, or whatever and extract whatever is needed from
> there to do the job.
Depending if you want to go that way (and how the current component is
set up): have a look at the SVN class I linked to see functionality that
figures out if there's an svn repository (i.e. checks for .svn
directory) and gets local revision etc.
Dawson,
thanks for your detailed feedback,
Reinier
More information about the Lazarus
mailing list