5.2. IDE workflow

This section introduces you to using Git from within the Eclipse IDE.

There are 3 training repositories available, set up so that they can mimic our development workflow.

  • Each repository contains multiple projects.
  • Each repository has branches called master, 8.16, 8.14
  • The contents themselves are minimal, just a few files.
  • The repositories and their contents are:



Confirm that you have access to the training repositories

$ ssh dascgitolite@dasc-git.diamond.ac.uk info      # issue command exactly as it appears, don't change the userid
                                                    # if you are prompted for a password, there is an error in the setup
  @C @R   W      training/${USER}/workflow\..*      # you can create and update the training repositories for your userid
     @R_         training/template/workflow\..*     # you can read the training repository templates

5.2.1. Copy the training repositories

First make a copy, on the remote Git server, of the remote training repositories, using this command line script (download):

rm -rf ${work_dir}
mkdir ${work_dir}

for repository in "a" "b" "master"; do
  cd ${work_dir}
  git clone dascgitolite@dasc-git.diamond.ac.uk:training/template/workflow.${repository}.git
  cd workflow.${repository}
  git remote set-url origin dascgitolite@dasc-git.diamond.ac.uk:training/${USER}/workflow.${repository}.git
  for branch in "8.14" "8.16" "master"; do
    git checkout ${branch}
    git push origin ${branch}:refs/heads/${branch} --verbose  # (re-)create our private remote

rm -rf ${work_dir}                                  # having created a remote copy of the remote repositories, delete the temporary copy 

If you have previously copied the repositories, and wish to re-initialise them, simply run the above script again.

5.2.2. Check out the training repositories

Start your Eclipse IDE, pointing to a new workspace.

  1. At Project, de-select Build automatically
  2. Open the console view at Window ‣ Show View
  3. Open the Git Repositories and Git Staging views.
  4. Open Buckminster CQuery https://alfred.diamond.ac.uk/buckminster/base/training-trunk.cquery
  5. On the Main tab, specify a component name of workflow.master.feature and a component type of eclipse.feature
  6. On the Properties tab, change training.repository.user to your FedID
  7. Resolve and Materialize, then enjoy!

Git repositories are cloned outside the workspace, in a directory called ${workspace_loc}_git, and imported into your workspace as existing projects.

Other possible checkout options:

  • For the training/workflow.small repository, specify a component name of workflow.small (and leave component type unspecified).
  • For the IDE training repositories v8.16, specify CQuery https://alfred.diamond.ac.uk/buckminster/base/training-v8.16.cquery Didn’t work?

Did you:
Issue the ssh dascgitolite@dasc-git.diamond.ac.uk info command to check your access?
Create the remote copy of the training repositories?
Set the training.repository.user property?
Once you have fixed the problem, you need to:
Delete the ${workspace_loc}_git directory
Restart Eclipse

5.2.3. Use EGit

more to come