Skip to content

Updating THOR and Alfrodull code from GitHub

nabajour edited this page Jul 20, 2020 · 1 revision

Alfrodull is a git submodule in the THOR repository. That means both can actually be treated as separate git repositories. But they need to have code that is in sync.

(THOR has information to point to a version of Alfrodull that is in sync with it, but with multiple development branches, updating them in sync can be a bit finicky, simplest is to update them separately as below).

Updating THOR and Alfrodull to latest version

Before updating, check the branch you are on (see below) and then get the latest version.

In THOR directory, on dev branch, pull the latest:

thoruser@~/ $ cd prog/THOR
thoruser@~/prog/THOR $ git pull

Then, in alfrodull subdirectory, on it’s master branch:

thoruser@~/prog/THOR $ cd Alfrodull
thoruser@~/prog/THOR/Alfrodull $ git pull

You can check the history to see if you’re at the correct step.

Git tips

Checking the branch you are on

thoruser@~/prog/THOR $ git branch                                                                     
* dev
  main                                        

Shows you’re on branch dev. You can change branch with git checkout <branchname>.

Checking the local status of your directory

The command git status shows if you have local changes and on what branch you are.

Checking what history to see the version of the code you have

The command git log shows you the history of the branch you are on, with the latest commit on top. (Quit by presssing q).

commit 0b682a7d685fdb0840d3ff346aede3ccb5dc8655
Author: nab <[email protected]>
Date:   Wed Jul 15 19:01:48 2020 +0200

    fix include

commit af7fced9caba1ec922a11118086f63198ec1ae2d
Author: nab <[email protected]>
Date:   Wed Jul 15 18:37:18 2020 +0200

    scat corr and i2s tests

The top entry shows the latest version. It’s called a commit hash and is usually given with it’s first characters (e.g.: 0b682a)