wbsoft/frescobaldi — pull request #223 by uliska (2013-10-09 12:28:04+00:00)
Title: Please test Git menu

##### Disclaimer

This pull request is *not* intended to be merged. But I would like to have my work tested by others in other context as early as possible.

The current functionality isn't the ultimate goal. Managing Frescobaldi's source code repository is just simpler Git-wise, so I use this to develop the basic infrastructure to build upon later when we're talking about VCS workflows for working with LilyPond projects.

##### What it does

- Implement the foundation of VCS support
-> a `vcs` module with a `AbstractVCSRepo` class, a derived `GitRepo` class and the option to support other VCSs in the future.
- `File->Restart Frescobaldi` menu item.
This is already in master but should be considered in this context
(only visible when Frescobaldi is run from Git)
- Display repo info in the title bar:
- current branch
- remote this branch is tracking (if it does)
- optionally the name of the remote branch if it differs from the local name
- `Git` menu

The new menu currently only shows a list of local brances (with remote info).
When selecting an entry Frescobaldi tries to `checkout` this branch and restart itself.
When Git fails (because the working tree isn't clean for example) it aborts with a message.
When it succeeds one is notified and can chose to restart the application.

##### What to test

- Does the title bar always show correct information?
- Does `File->Restart Frescobaldi` work correctly?
- Does the `Git` menu show the right entries and works correctly when selecting one?

Please note one (inherent) glitch: When chosing a different branch this will most likely *not* contain the Git functionality. So Frescobaldi will restart but run a version without the Git menu. Maybe you could create a few dummy branches on top of `git-menu` to test.

##### What will come in addition

The current functionality isn't *that* much, but as said it's mostly the foundation for later real-world applications.
The next two things I would implement are:

- `Git->Update Frescobaldi`
Look for updates on `master`. This can be made to optionally perform on program startup.
- Add submenus for all registered remotes
Show the branches of all registered remotes (e.g. upstream, your fork and other contributors' forks).
The idea is to make collaboration more transparent: you can easily see from within Frescobaldi, who has new material you could check out.

When these two things have been implemented and are stable I intend to ask for merging into `master`.