The Git (source code management) sidebar allows you to perform specific Git operations from within Nova. Nova’s git support is built-in and does not require any additional software to be installed.
To use the Git sidebar, you must open a Workspace that contains an existing Git repository. If your current workspace is not in a Git repository, the Git sidebar will give you the option to initialize one.
When working in a Git repository, you’ll see your current branch displayed in the main toolbar below the name of your project. You’ll also find a variety of options available in the Git Sidebar. The first menu allows you to choose between the main repository, or any subrepositories in the project, such as submodules. The second menu allows you to switch between branches in the selected repository. Below that, you’ll find a toolbar. The buttons on the right allow you to Fetch, Pull, and Push changes to or from your remote repository. These actions can also be accessed from the Project > Git menu.
On the left, you can switch between several different views:
Shows an overview of the branches, tags, remotes, and submodules within the current repository. Entries can be expanded for further detail, such as seeing a list of branches available on a remote repository.
Shows a list of uncommitted changes to the repository. From here, you can choose to commit them or write a commit message. You can select which files you wish to stage by checking them off in the list, or click “Stage All” to stage all changes for committing. The icons to the right of each file indicate its status, such as being modified, deleted, or not previously tracked in the repo.
You can select the History list to view previous commits. Double-click a previous commit to view details about the commit including its SHA hash, plus additional options such as making a new branch, tagging, or checking out the commit.
A full discussion on how to use source control is beyond the scope of this article. Please refer to the Git User Guide for more information.
Using Git Accounts in Nova
Nova currently supports seven types of Git accounts: GitHub, GitHub Enterprise, GitLab, self-hosted GitLab, Gitea, Bitbucket Cloud, and Bitbucket Server. You can add any of these Git accounts under Settings > Git Accounts.