From mboxrd@z Thu Jan 1 00:00:00 1970 From: wilhelm.matilainen at gmail.com (Wilhelm Matilainen) Date: Sun, 5 Oct 2014 15:25:21 +0300 Subject: Fwd: JSON interface In-Reply-To: <20141005120540.GA1749@serenity.lan> References: <20141005120540.GA1749@serenity.lan> Message-ID: That's what I'm interested in doing. There just has to be some reverse proxied application that will handle the requests to git with security in mind. 2014-10-05 15:05 GMT+03:00 John Keeping : > On Sun, Oct 05, 2014 at 02:13:35PM +0300, Wilhelm Matilainen wrote: > > Instead of acting as a server providing html and css files, could there > be > > a only-json option? > > You can already configure the URL for CGit's CSS and logo files to point > at a separate machine if you want to do that. > > > I could then provide all the static files minified and cached from a > proper > > http server already in use and request only the data from cgit. > > > > Using jquery: > > ----------------------------------------------- > > $.getJSON('/git/repository/', function(data) { > > showRepo(data); > > }); > > ----------------------------------------------- > > > > By loading https:// > > /git//// > > CGit would output something like: > > ----------------------------------------------- > > { > > "repository": "test", > > "property1": "value1", > > "property2": "value2" > > } > > ----------------------------------------------- > > I don't think it would be particularly difficult to add a new "json" URL > in cmd.c and handle all of the necessary sub-options, but you would then > need to write an entire UI in JavaScript. > > At that point, I'm not sure it would be CGit any more since you would be > using essentially none of the code that exists now. > -------------- next part -------------- An HTML attachment was scrubbed... URL: