Squeak
  links to this page:    
View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide
Git Browser
Last updated at 9:14 pm UTC on 3 June 2020
The Git Browser is a graphical user interface to operate on Smalltalk projects that are tracked in Git repositories. It allows you to manage working copies, track packages (multiple per working copy, which are all versioned together), browse branches, create new commits, search for commits, synchronize with remote repositories, and perform checkouts and merges. It can be used without a Git outside of Squeak (it does not call external processes or shared libraries).

The tool is primarily meant to maintain Squeak projects, which are published on GitHub or similar platforms, but can be used with any Git repository.

How to install the Git Browser


Install the Git Browser by choosing Tools > Git Browser in your Squeak image (since 5.2). This will also load several of dependencies via Metacello.

How to use the Git Browser


Once you have the Git Browser opened from the Tools menu for the first time, it will prompt you whether you want to create your first project now. If you would like to start a fresh and empty working copy on an empty Git repository, select “yes” and provide a path for the Git repository. If you would rather like to clone an existing Git repository, select “no.”

The Git browser itself has five panes:






Between the panes, there is a strip of buttons. They operate on the current branch or the selected commit. At the far right, you can configure how things go to Git: that is your name and e-mail address for the commit metadata, the Smalltalk file format you want to produce (FileTree/Cypress or Tonel), and whether Squot should suppress writing its own configuration files (if you want to submit a pull request to a repository that is not developed with Squot, for example). Via the Feedback button, you can create an issue for Squot on GitHub directly from the image. You can also file these here: https://github.com/hpi-swa/Squot/issues

To add another package to a project, or remove a package from the set of tracked packages, open the menu of a project and choose “Change tracked packages”. Below that menu item, you can also change between writing FileTree/Cypress or Tonel files (“Set package storage format…”).

When you switch branches via the context menu of the branch list, note that it will stow away all your unsaved changes and the other branch is checked out clean. Your unsaved changes will be restored when you switch back to the original branch. This behavior is different from the Git CLI, and was conceived in an alternative Git frontend called “Gitless” (which addresses some of Git’s awkwardness).

When you want to commit, you will find that there is no Git staging area as far as the Git Browser and accompanying tools are concerned. Instead, you can choose which packages, classes, and methods you want to include or exclude in the commit dialog, like in Monticello in recent years.

When you checkout or merge something, you always first get a list of changes, from which you can choose what to load and what to skip.

To update the Git Browser when a new version was published, open the window dropdown menu (third button from the right in the title bar) and choose “self-update…”. It pulls the latest version from the master branch on GitHub. Ongoing development happens on the “develop” branch, not on master. You can also pull that version by choosing “set self-update branch…” in the same menu, and then invoke the update.

Which version control packages lie beneath the Git Browser


The Git Browser uses Squot to realize version control, not Monticello (although Squot uses parts of Monticello under the hood).

The adapter between Squot and Git uses a package called FileSystem-Git, which contains a pure Smalltalk implementation of Git.

Further Information


The Git Browser is hosted together with Squot and the used version of FileSystem-Git on https://github.com/hpi-swa/Squot/

Current open issues are tracked here: https://github.com/hpi-swa/Squot/issues