Skip to content

Commit 0d9b15d

Browse files
committed
Merge branch 'main' into spack-reworking
2 parents 0e09d60 + 4002d77 commit 0d9b15d

3 files changed

Lines changed: 29 additions & 3 deletions

File tree

01_version_control/my_favorite_neat_little_git_trick_demo.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
- Preparation should not take longer than 15 mins, should be a demo.
55
- Lecturers also prepare some.
66

7-
## Tricks from Winter Team 2025/26
7+
## Tricks from Winter Term 2025/26
88

99
- Click on line number on GitHub and then `blame` to study history of file
1010
- GitHub uses [gitignore templates](https://github.com/github/gitignore) if you create a `.gitignore` file from GitHub
@@ -18,6 +18,22 @@
1818
- If you rebased/merged and messed up your history, use `git reflog` to go back to a previous state
1919
- If you only need one file from another commit or branch, use `git checkout <branch_or_sha> -- <path>`
2020
- Use [Git LFS](https://git-lfs.com/) for big files >10 MB or for non-diffable binaries (e.g., images, media, archives, shared libraries).
21+
- Use `git switch -c <branch-name>` to create a new branch and immediately check it out!
22+
- Don't get stuck thinking that branches are only used as feature branches or issue branches! You can always create a short-lived temporary branch for something small, like shelving an experimental change.
23+
- If a temporary branch is still too much overhead for you, you can instantly stash your local changes with `git stash`. Restore your stashed changes later with `git stash pop`.
24+
- Prefer `git add -p` over `git add [FILE]`. This allows you to specify what you want to add to a commit in a more fine-grained manner
25+
- A very nice alias for editing any earlier commit, without having to manually rebase:
26+
27+
```
28+
[alias]
29+
amend = "!f() { \
30+
COMMIT=$(git rev-parse --short \"$1\") && \
31+
git commit --fixup \"$COMMIT\" && \
32+
GIT_SEQUENCE_EDITOR=true git rebase --autosquash --autostash --interactive "$COMMIT^"; \
33+
}; f"
34+
```
35+
36+
Usage: e.g. `git add -p ...` and then `git amend HEAD~5`. This would add the staged changes to the fifth last commit.
2137
2238
## Tricks from Winter Term 2024/25
2339

03_building_and_packaging/cmake_exercise.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ In this exercise, we need to fight. Not everything always works smoothly. This i
44

55
To get an independent and reproducible environment as common ground, we use and, thus repeat, Docker.
66

7-
Deadline: **Wednesday, November 27th, 2024, 9:00**
7+
Deadline: **Wednesday, November 26th, 2025, 9:00**
88

99
## Overview
1010

11-
- The goal of the exercise is to open a pull request from a fork of [the CMake exercise repository](https://github.com/Simulation-Software-Engineering/cmake-exercise-wt2425). Please name your pull request `Add building and container recipes` and assign yourself.
11+
- The goal of the exercise is to open a pull request from a fork of [the CMake exercise repository](https://github.com/Simulation-Software-Engineering/cmake-exercise). Please name your pull request `Add building and container recipes` and assign yourself.
1212
- Your pull request should add a `Dockerfile` and a `CMakeLists.txt`, besides some minor changes in `main.cpp`, such as commenting in some code parts.
1313
- From your pull request, it should be possible to create an executable container. After running the container, it should be possible to `cd` into `cmake-exercise` and then run the `build_and_run.sh` script.
1414
- Use as many of the currently commented-out additional files, which induce additional dependencies.

timetable.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,3 +54,13 @@
5454
## 5.2 – Wed, November 12, 2025
5555

5656
- **90** min.: [Exercise on Packaging a Python Code](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/pypi_exercise.md)
57+
58+
## 6.1 – Wed, November 19, 2025
59+
60+
- **25** min.: Some Linux fundamentals: [slides](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/linux_fundamentals_slides.md), [demo](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/linux_fundamentals_demo.md)
61+
- **20** min.: Introduction to Make: [slides](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/make_slides.md), [demo](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/make_demo.md)
62+
- **45** min.: Introduction to CMake: [slides](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/cmake_slides.md), [demo](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/cmake_demo.md)
63+
64+
## 6.2 – Wed, November 19, 2025
65+
66+
- **90** min.: [Exercise: Let's Fight With CMake, Docker, and Some Dependencies](https://github.com/Simulation-Software-Engineering/Lecture-Material/blob/main/03_building_and_packaging/cmake_exercise.md)

0 commit comments

Comments
 (0)