jonpither / cider-spy

Multi person REPL & lets developers share information on CIDER nREPL sessions
22 stars 4 forks source link

See other devs GIT commits/branches/status #15

Open jonpither opened 10 years ago

jonpither commented 10 years ago

This is a fun hacky thing, not required for version 1. Probably not ethical, although sucking someone elses branch/stash/changes would be uber cool. Could be hard though.

Code mess-around on the steal-git branch

Git Integration Rumination

If I could integrate with GIT, then from the team status menu we should a quick summary. I.e. I hit tab on foo-developer, and I can see unpushed commit msgs and changes pending. This is kinda cool.

Technically it could work in 2 ways. Either through the Netty pipe we broadcast all git activity and the server keeps track, or we just do it request/response cycle. The former is hard as any GIT info can quickly become invalidated if people squash/rebase/stash etc. The latter is possibly simpler, just requires a bit of glue to make happen. (In future this could be expanded to do seriously funky git shit, like take a commit from someone, without them having to do anything.

So.. some funkage. Basically first story would be - fetch GIT summary (branch, commits pending, changes pending).

The potential downside is that this is proper invasive :-) I guess we can configure on/off. For this to work, unlike other functionality, it would require cider-spy to cider-spy communication.

git-index seems to be a way. magit-insert-staged-changes is interesting. the wash command works on the output of git-index. Git-index is basically the way.