[KDev4] vcs integration
Andreas Pakulat
apaku at gmx.de
Mon Mar 26 16:22:59 UTC 2007
On 26.03.07 15:34:46, Robert Gruber wrote:
> while having a look at the vcs exension interface the following questions came
> to my mind.
>
> As we can have multiple projects opened at a time, it may happen that files
> >from different projects will be passed to a VCS-plugin.
> *) How can I find out which file belongs to which project?
> *) And what if the project use different VCS plugins?
>
> I'll have to call the cvs client from a location inside of the local working
> copy and pass all files relative to that directory.
IIRC all IProjectFileManager's have way to find the relative path for a
given URL.
> I though the best thing
> would be to use the project directory as working directory and transform all
> given URLs to a path relative to that location. So at least for cvs, I need
> to have some sort of access to the projects the files belongs to.
>
> Maybe we shouldn't pass a list of KUrls but rather a list of objects from the
> ProjectFileItem class to the vcs plugins?!?!
I didn't yet look at the API but you are absolutely correct. In fact I
think we should discuss wether we want both, i.e. KUrl +
ProjectBaseItem*. I'm not sure we need KUrl, so I'd like to see people's
opinions on that part, are there any use cases anybody can think of?
This is also the only way to connect filemanger and vcs-plugin, i.e.
IFileManager::fileAdded(ProjectBaseItem*) signal should be connected to
VCS::addFile(ProjectBaseItem*) slot (this means pretty much all API
needs to be a slot).
Andreas
--
You will inherit millions of dollars.
More information about the KDevelop-devel
mailing list