mirror of
https://github.com/git-learning-game/oh-my-git.git
synced 2024-11-26 16:20:15 +01:00
33 lines
999 B
Text
33 lines
999 B
Text
title = This is the level's title
|
|
|
|
[description]
|
|
|
|
This text will be shown when the level starts.
|
|
|
|
It describes the task or puzzle the player can solve.
|
|
|
|
[congrats]
|
|
|
|
This text will be shown after the player has solved the level.
|
|
|
|
Can contain additional information, or bonus exercises.
|
|
|
|
[setup]
|
|
|
|
# Bash commands that set up the initial state of the level. An initial
|
|
# `git init` is always done automatically. The default branch is called `main`.
|
|
|
|
echo You > people_who_are_awesome
|
|
git add .
|
|
git commit -m "Initial commit"
|
|
|
|
[win]
|
|
|
|
# Bash commands that check whether the level is solved. Write these as if you're
|
|
# writing the body of a Bash function. Make the function return 0 if it's
|
|
# solved, and a non-zero value otherwise. You can use `return`, and also, Bash
|
|
# functions return the exit code of the last statement, which sometimes allows
|
|
# very succinct checks.
|
|
|
|
# Check whether the file has at least two lines in the latest commit:
|
|
test "$(git show HEAD:people_who_are_awesome | wc -l)" -ge 2
|