Skip to content

Instantly share code, notes, and snippets.

@wadoon
Last active January 30, 2023 17:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wadoon/352113e1f52dc6919ade0855d1b6c735 to your computer and use it in GitHub Desktop.
Save wadoon/352113e1f52dc6919ade0855d1b6c735 to your computer and use it in GitHub Desktop.

Dear KeYanians,

we are happy to announce, that KeY is finally on Github! The new home is https://github.com/keyproject/ with many repositories, for example,

Note, we rewrote the history of the KeY repository to remove large files from KeY's history. You are not able to further work with your old local working copy of the KeY repository. Please re-clone. We recommend the following setup:

$ git clone https://github.com/keyproject/key.git
$ cd key; git remote add keylab https://git.key-project.org/key/key.git
$ git fetch --all

You clone from the public and main source of KeY. If you are a KeY team member, we grant you write permission to the KeY repositories on request. Anything you want to make publicy available, i.e., things you want to be merged in the main branch, needs to push to the origin (aka. github.com/keyproject/key) repository. Under keylab you can access private branches.

Merges are performed via Pull Requests (in Gitlab called Merge Request) and need to pass our code checks and approval. We renamed the master branch to main. You can simply publish a branch as before:

$ git push origin weigl/feature1

Write permission to github.com/keyproject/key is not granted for short-term contributors, for example, students writing their thesis. These contributors need to fork KeY at Github and provide their contributions as pull requests or have a patron (e.g, the supervisor) who pulls from keylab and pushes the branch to origin. Permission to git.key-project.org are handled as before.

Note, that origin only contains the release and main branches. You should use origin/main as the source for new branches. Your "private" branches are still alive on keylab (aka. git.key-project.org/key/key). You can check them out with

$ git checkout -b rule_the_world keylab/weigl/my_secret_feature

Your "secret" developments should only be pushed to keylab:

$ git push keylab weigl/top_secret_branch

Issues

We migrated the issues from Gitlab to Github, mainly, to preserve the numbering of the issues. Only title, status, labels, and the description (body) of the issues have been migrated, but not any comments.

Issues will remain viewable and editable in the old system. Additional to these ca. 1750 issues, we have reserved the issues upto 2999 on Github, in the hope that the number of the Gitlab issue numbers won't collide with the numbering on Github.

We continue to to adjust and configure our new Github home for our needs until everything will run smoothly, but this should not prevent you from coding happily on KeY.

Merge Requests

Merge Requests were not transfered to Github. Due to the renaming of the our main branch, I have updated the target branch in all affected Merge Requests, which has triggered the pipelines. The pipelines have been stopped, please re-trigger if analyses status are overwritten.

Note, that merging branches in the main branch is forbidden on keylab (enforced by branch protected) to avoid diverging main branches between Github and Gitlab.

Error Recovery

The rewriting of the KeY history produces artifacts that might be help if you have an old repository. In the gist, you find artifacts which describes the mapping of old commits/refs to new commits/refs. You also find the filter-command to rewrite the history locally.

If you have any question, feel free to ask.

Regards,

Alexander

@WolframPfeifer
Copy link

I think the second code line in the text should read:
$ cd key; git remote add keylab git@git.key-project.org:key/key.git for ssh and
$ cd key; git remote add keylab https://git.key-project.org/key/key for https.

@wadoon
Copy link
Author

wadoon commented Jan 30, 2023

I updated the text accordingly.

I would recommend to use a fork of KeY for development:

  1. Create a fork
  2. Checkout KeY
git clone git@github.com:keyproject/key.git
cd key
git remote add keylab git@git.key-project.org:key/key.git
git remote add mine git@github.com:wadoon/key.git
  1. Optional: Copy your branches from keylab to your fork mine.
  • Local checkout:
for br in $(git branch -r | grep keylab/weigl/); do
	short=${br:7}
	echo $short
	# ignore errors
	git checkout -b $short $br || true
done
  • And push:
$  git push mine -u $(git branch)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment