Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 339351 - [server] Git status should return all changes in the repo
Summary: [server] Git status should return all changes in the repo
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 0.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 0.2   Edit
Assignee: Tomasz Zarna CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-09 09:07 EST by Szymon Brandys CLA
Modified: 2011-09-01 11:42 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Szymon Brandys CLA 2011-03-09 09:07:31 EST
I had a discussion with Boris about how Git Status works.

Right now Orion Git status returns changes for the selected folder only. Boris claims that it should work similarly to console Git status, what means it should return all changes in the repo. It makes sense since Git commit (on the status UI) commits all staged changes, not only these in the selected folder. That's why I would agree with Boris.

Objections?
Comment 1 Boris Bokowski CLA 2011-03-09 09:12:01 EST
Do you believe this would require a change to the Git server API, or could it be handled on the client side?
Comment 2 Boris Bokowski CLA 2011-03-09 09:12:25 EST
Btw, the Git Status page should show the name of the project it is showing status for.
Comment 3 Tomasz Zarna CLA 2011-03-09 10:02:59 EST
(In reply to comment #1)
> Do you believe this would require a change to the Git server API, or could it be
> handled on the client side?

The easiest fix would be to hide "Git status" action for items other then top-level folders. But a proper fix would require a change on the server side. I'm on it, I was about to have a look at Git server API for status anyway - bug 339341.
Comment 4 Szymon Brandys CLA 2011-03-09 11:32:11 EST
(In reply to comment #2)
> Btw, the Git Status page should show the name of the project it is showing
> status for.

Project or selected subfolder. I raised Bug 339385 for it.
Comment 5 Tomasz Zarna CLA 2011-03-09 12:04:45 EST
Fixed with 51b73556d8c9f3d2802e423fb58c1692cd0bf46f.

/git/status response returns all changes now. There is a new entry called "Path"[1] which contains a relative path (eg. "../file.txt"). 

Libing, I'm not sure which one is better for you "Name" or "Path", but displaying "Path" would give a result similar to using git CLI. Trying to get status for a file will return 400 - bad request. Szymon will try to turn off the status action for files (bug 339393).

[1] org.eclipse.orion.server.git.GitConstants.KEY_PATH