Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [orion-dev] .gitignored files decoration

On Tue, Nov 3, 2015 at 7:03 AM, Rozenszajn, Sergio <sergio.rozenszajn@xxxxxxx> wrote:

Hi,

 

In our web IDE client we are requested to provide a decoration for .gitignored files.

I found that it is possible to PUT ignored files in .gitignore using GitServlet.java via GitIgnoreHandlerV1.java.

Unfortunately only PUT is supported and we would need a GET to get all ignored files in a project.

Another thing that I noticed in GitIgnoreHandlerV1 is that if you call it multiple times with same path, it will be added multiple times to .gitignore.

 

Note that native git supports listing ignored files via command git ls-files --others -i --exclude-standard.

 

Questions:

·         is there a way to get all .gitignored files in Orion or it is just missing?

·         If we have to code this by ourselves (we did not decide yet if to code it in client or server)  is possible to list .gitignored files with jgit?

using JGit create an IndexDiff and call getIgnoredNotInIndex()

In EGit we cache the IndexDiff and incrementally update it based on events emitted by the resource model in
the Eclipse platform when files in the workspace change in order to improve performance. The EGit staging view
basically displays the cached IndexDiff and is updated incrementally based on incremental IndexDiff updates
which are computed in a resource change event listener.

-Matthias

Back to the top