diff --git a/materials/slides/collaboration.typ b/materials/slides/collaboration.typ index 1ca0a6235f393b63b3d7ef36409e7a9d0f06814e..5e6fc75ae564fd1c945248b798ae682df04b01bd 100644 --- a/materials/slides/collaboration.typ +++ b/materials/slides/collaboration.typ @@ -1,6 +1,6 @@ #import "@preview/touying:0.5.3": * -= Collaboration += Best Practices == Wie sieht ein guter Commit aus? === Vollständig @@ -9,44 +9,84 @@ Vor und nach dem Commit sollte alles außer dem beabsichtigten geänderten Verha === Atomic Wenn es sinnvoll sein kann den Commit teilweise zu reverten, ist er zu groß. -== The Not Rocket Science Rule Of Software Engineering -"maintain a branch that always passes all the tests" +// == The Not Rocket Science Rule Of Software Engineering +// // https://graydon2.dreamwidth.org/1597.html +// Maintain a branch that always passes all the tests\ +// - basierend auf Regel von Graydon Hoare -Implemented in: -- #link("https://docs.gitlab.com/ee/ci/pipelines/merge_trains.html")[GitLab: Merge Trains] -- #link("https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/managing-a-merge-queue")[GitHub: Merge Queues] +// Implemented in: +// - #link("https://docs.gitlab.com/ee/ci/pipelines/merge_trains.html")[GitLab: Merge Trains] +// - #link("https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/managing-a-merge-queue")[GitHub: Merge Queues] == Wie sieht eine gute Commit Message aus? So nicht. #align(center, link("https://github.com/MontiCore/monticore/commits/dev/?after=f7fb15d399f3283af3e9c8a795bf3366768870d6+90", image("/images/BR.png", height: auto))) +#let pad-spaces(n, width) = { + let s = str(n) + if s.len() < width { + return " " * (width - s.len()) + s + } + return s +} +#show raw.where(block: true): code => { + show raw.line: line => { + text(fill: gray)[#pad-spaces(line.number, 2)] + h(1em) + line.body + } + code +} + == Wie sieht eine gute Commit Message aus? Beispiel +// #link( +// "https://github.com/bevyengine/bevy/commit/0ac495f7f42ec91e2d215e5afa56d9c4a9c1741f", +// ```txt +// Remove accesskit re-export from bevy_a11y (#16257) + +// # Objective +// - Fixes #16235 + +// ## Solution +// - Both Bevy and AccessKit export a `Node` struct, to reduce confusion +// Bevy will no longer re-export `AccessKit` from `bevy_a11y` + +// ## Migration Guide +// - Users will need to add `accesskit = "0.17"` to the dependencies +// section of their `Cargo.toml` file and update their `accesskit` use +// statements to come directly from the external crate instead of +// `bevy_a11y`. +// - Make sure to keep the versions of `accesskit` aligned with the +// versions Bevy uses. +// ``` +// ) #link( -"https://github.com/bevyengine/bevy/commit/0ac495f7f42ec91e2d215e5afa56d9c4a9c1741f", -```txt -Remove accesskit re-export from bevy_a11y (#16257) - -# Objective -- Fixes #16235 - -## Solution -- Both Bevy and AccessKit export a `Node` struct, to reduce confusion -Bevy will no longer re-export `AccessKit` from `bevy_a11y` - -## Migration Guide -- Users will need to add `accesskit = "0.17"` to the dependencies -section of their `Cargo.toml` file and update their `accesskit` use -statements to come directly from the external crate instead of -`bevy_a11y`. -- Make sure to keep the versions of `accesskit` aligned with the -versions Bevy uses. -``` +"https://cbea.ms/git-commit", + ```txt + Summarize changes in around 50 characters or less + + More detailed explanatory text, if necessary. Wrap it to about 72 + characters or so. In some contexts, the first line is treated as the + subject of the commit and the rest of the text as the body. The + blank line separating the summary from the body is critical (unless + you omit the body entirely); various tools like `log`, `shortlog` + and `rebase` can get confused if you run the two together. + + Explain the problem that this commit is solving. Focus on why you + are making this change as opposed to how (the code explains that). + Are there side effects or other unintuitive consequences of this + change? Here's the place to explain them. + + If you use an issue tracker, put references at the bottom: + Fixes: #123 + See also: #456, #789 + ``` ) == Wie sieht eine gute Commit Message aus? #v(1fr) === Was ich aus der Message lernen soll -- Welche Verhaltensänderung wurde beabsichtig? +- Welche Verhaltensänderung wurde beabsichtigt? - Warum gibt es diese Änderung? - "If applied, this commit will ..." oder "After this commit, the program will ..." @@ -64,6 +104,6 @@ versions Bevy uses. - Imperativ - Großgeschrieben anfangen - Ohne Punkt am Ende -- Titel $approx 50$ Zeichen, maximal $72$ +- Titel $< 50$ Zeichen, maximal $72$ #v(1fr) \ No newline at end of file