1
python analysis code
Sven Augustin edited this page 2025-06-12 15:34:08 +02:00

Analysis code git repository

https://gitlab.psi.ch/maloja/analysis/

Getting started

Create/enter a folder, where you want to store git repos:

mkdir ~/git
cd ~/git

Clone via either

ssh: git clone git@gitlab.psi.ch:maloja/analysis.git maloja-analysis

or

https: git clone https://gitlab.psi.ch/maloja/analysis.git maloja-analysis

[ssh needs a public ssh key, https asks for your PSI account credentials.]

You now have your local copy of the analysis codes in the ~/git/maloja-analysis/ folder. Place your files into this folder. Feel free to create subfolders as well. Finally, you add and commit your files with a description:

git add *.py *.ipynb
git commit -m"added some scripts/notebooks that do this and that."
git push

Working on codes

Before you start working on code, you should run

git pull

in the folder (e.g., ~/git/maloja-analysis/) to get the latest updates from everyone.

After you changed something, you simply add/commit/push again.

ssh keys

On each computer, you want to access the repo from, generate a key via ssh-keygen. Open the resulting file, and copy/paste the public key here:

https://gitlab.psi.ch/profile/keys