Compare commits

...

37 commits
0.6.3 ... main

Author SHA1 Message Date
Marcel Ribeiro-Dantas 9da0bd1fbd Fix typos 2024-02-13 15:20:04 +01:00
bleeptrack ce9fcda773
Merge pull request #173 from derNiklaas/fix-readme-logo
Fixed Logos for organizations that fund the project
2023-05-11 14:08:37 +02:00
bleeptrack 2aeef1d053
Merge pull request #174 from Jayman2000/clarify-godot-requirements
Clarify Godot requirements
2023-05-11 14:07:37 +02:00
Jason Yundt 8e9617af93 Clarify Godot requirements
At the moment, the most recent commit to the main branch was created
before Godot 4 was released [1] [2]. When that commit was created, it
was accurate to tell users to download the latest version of Godot
because the latest version of Godot was a version of Godot 3. Now, that
statement is no longer accurate because the latest version of Godot is
a version of Godot 4, and Oh My Git! hasn’t been ported to Godot 4 yet.

It’s possible that we can just import Oh My Git! into Godot 4 and have
it work fine, but that would require significant testing that I’m not
going to do at the moment.

[1]: 853b8e2 (Merge pull request #144 from n4mr3g/patch-1, 2022-07-19)
[2]: <https://godotengine.org/article/godot-4-0-sets-sail/>
2023-05-11 07:49:51 -04:00
Niklas 70c0d5576f
Removed lines left over from pasting the images 2023-04-18 16:19:51 +02:00
Niklas 73966b27bb
Fixed Logos for organizations that fund the project 2023-04-18 16:18:09 +02:00
blinry 853b8e2d53
Merge pull request #144 from n4mr3g/patch-1
Added info of the 'friend' repo, that the player needs to clone, in the level description.
2022-07-19 14:50:16 +02:00
blinry 562816b5a2
Merge pull request #137 from Elatronion/patch-1
fix typo in bisect level Yellow brick road
2022-07-19 14:46:43 +02:00
blinry 727a32d72f
Merge pull request #119 from kmomberg/fix-revert-card-desc
Fix typo in revert description card
2022-07-19 14:45:46 +02:00
Germán Piccioni d67e5056ea
Added in the description the location of the repo to clone. 2022-06-20 01:33:30 +02:00
Elatronion 0ea34e6bd9
fix typo in bisect level Yellow brick road
`"bisect good card"` has been changed to `"bisect good" card` to be more accurate and consistent with `"bisect start" card` and `"bisect bad" card`.
2022-02-16 21:38:05 -05:00
Kurt c8ea26ecbb
Fix typo in revert description card 2021-05-14 22:58:01 -04:00
blinry 929c634cc4
Merge pull request #111 from MK-UDUE/patch-3
Fixed small typo "named" instead of "names"
2021-05-10 12:16:48 +02:00
blinry b9dff307b2
Merge pull request #110 from MK-UDUE/patch-2
Suggesting pushing rather than pulling
2021-05-10 12:16:02 +02:00
blinry 5e0af1d2f1
Merge pull request #108 from nikopp/patch-1
Fixed typo in reflog description.
2021-05-10 12:15:28 +02:00
blinry 2bb5d4c4b3
Merge pull request #96 from artt/patch-1
Fixed typo in files > add level
2021-05-10 12:15:00 +02:00
blinry 5b8fc43026
Merge pull request #94 from Tokugero/patch-1
Sample of making this level more clear.
2021-05-10 12:13:48 +02:00
MK-UDUE c117503375
Fixed small typo "named" instead of "names" 2021-04-29 19:15:48 +02:00
MK-UDUE b64aeef896
Suggesting pushing rather than pulling
Twice pulling doesn't make sense (to me).
2021-04-29 19:10:02 +02:00
nikopp 98ffccf515
Fixed typo in reflog description. 2021-04-25 21:30:44 +02:00
Art Tosborvorn 6a7c1eab6f
Update files-add
Fixed it's -> its typo.
2021-04-15 09:10:51 +07:00
Tokugero f9123b5652
Sample of making this level more clear.
It wasn't at all clear how to solve this until I came to look at the actual tests. The first win condition step also didn't display which may have been a result of the  format? Here's an example of something that might be more clear to the player.
2021-04-13 12:42:51 -07:00
blinry 1606e0565e
Merge pull request #59 from mundifex/stash-deadlock-fix
Fix deadlock in stash levels
2021-04-12 16:48:31 +02:00
blinry b8a18c4c2e
Merge pull request #88 from RedXanadu/main
Corrected spelling mistake
2021-04-12 16:40:11 +02:00
blinry e8b8583f49 Simplify the win condition for the remotes/problems level
Basically, the level now accepts every compromise, and just looks at the
shape of the commit graph.

Closes #87.
2021-04-12 16:23:59 +02:00
blinry ffadebb0df Simplify careful_delete even more by relying on user:// on each OS
Closes #83.
2021-04-12 16:03:11 +02:00
blinry 3211cd0481 Use HOME variables in careful_delete
This helps in cases where the home directory is in unexpected places,
like on external hard drives, and should still be very safe.

Closes #60, closes #81.
2021-04-12 15:49:20 +02:00
blinry 2b3903a599 Clarify instructions for the "Moving branches around" level
Closes #77.
2021-04-12 15:22:02 +02:00
blinry 74b59cff0a Double-check that players solved the "merging timelines" level correctly
Fixes #75.
2021-04-12 15:14:32 +02:00
Xanadu 7df6b60fa3 Corrected spelling mistake 2021-04-04 19:09:26 +01:00
blinry 44666d59ef
Merge pull request #82 from blanorama/patch-1
fix: typo in level stash
2021-03-30 18:10:58 +02:00
blinry 3e5c422663
Merge pull request #80 from mundifex/reorder-perl
Make reorder level winnable on macOS platforms by using perl instead …
2021-03-30 18:09:53 +02:00
Eugen Blattner cb1c0c2848
fix: typo in level stash 2021-03-29 02:02:41 +02:00
mundifex c2a2f87f4c Fix deadlock in stash levels
- use vertical tab character instead of "MAGIC" string to denote end of input
- check for terminator using pattern match instead of eq

Users are unable to provide special characters to Bash process so this should
be relatively safe. Pattern match succeeds even when `git stash` omits newline
while rendering commit subjects.

Fixes git-learning-game/oh-my-git#56
2021-03-26 21:34:22 -05:00
Ben Donatelli 5b12679988 Make reorder level winnable on macOS platforms by using perl instead of grep
macOS provides BSD grep which does not support -P flag. Perl pattern match
works on all platforms.

Fixes git-learning-game/oh-my-git#79
2021-03-26 20:38:15 -05:00
blinry f8f562b742
Merge pull request #53 from mundifex/main
Force grep command to use UTF-8 locale in solution for 'reorder' level
2021-03-25 07:06:27 +01:00
Ben Donatelli b99510dea7 Force grep command to use UTF-8 locale in solution for 'reorder' level 2021-03-09 22:14:48 -06:00
19 changed files with 41 additions and 34 deletions

View file

@ -16,12 +16,12 @@ If you have ideas for new features, we'd be excited to hear them! Also in that c
Wanna build your own level? Great! Here's how to do it:
1. Download the latest version of the [Godot game engine](https://godotengine.org).
1. Download the latest version of the [Godot **3** game engine](https://godotengine.org/download/3.x). Godot 4 is not supported yet.
1. Clone this repository.
1. Run the game the easiest way to do so is to run `godot scenes/main.tscn` from the project directory.
1. Get a bit familiar with the levels which are currently there.
1. Take a look into the `levels` directory. It's split into chapters, and each level is a file.
1. Make a copy of an existing level or start writing your own. See the documention of the format below.
1. Make a copy of an existing level or start writing your own. See the documentation of the format below.
1. Write and test your level. If you're happy with it, feel free to send it to us in a pull request! <3
### Level format
@ -89,7 +89,7 @@ We have a [Code of Conduct](CODE_OF_CONDUCT.md) in place that applies to all pro
## Funded by
<a href="https://www.bmbf.de/en/"><img src="https://timelens.io/assets/images/bmbf.svg" alt="Logo of the German Ministry for Education and Research" height="100px"></a>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <a href="https://prototypefund.de/en/"><img src="https://timelens.io/assets/images/prototypefund.svg" alt="Logo of the Prototype Fund" height="100px"></a>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <a href="https://okfn.de/en/"><img src="https://timelens.io/assets/images/okfde.svg" alt="Logo of the Open Knowledge Foundation Germany" height="100px"></a>
<a href="https://www.bmbf.de/en/"><img src="https://www.dipf.de/en/images/BMBF_4C_M_e.jpg/@@download/image/BMBF_4C_M_e.jpg" alt="Logo of the German Ministry for Education and Research" height="100px"></a>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <a href="https://prototypefund.de/en/"><img src="https://raw.githubusercontent.com/prototypefund/ptf-ci/main/logos/PrototypeFund-Icon.svg" alt="Logo of the Prototype Fund" height="100px"></a>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <a href="https://okfn.de/en/"><img src="https://upload.wikimedia.org/wikipedia/commons/4/4d/Open_Knowledge_Foundation_Deutschland_Logo.svg" alt="Logo of the Open Knowledge Foundation Germany" height="100px"></a>
## Thanks

View file

@ -9,7 +9,7 @@ Oh no! You have lost your key at some point during the day!
Sure, you could look at every single commit in an attempt to find it - but there's a better way: your time machine has a built-in way to find the point in time where things went wrong quickly!
First, play the "bisect start" card. Then, go to a commit where you don't have the key, and play the "bisect bad" card. Likewise, go to a commit early on where you have the key *in your pocket*, and play the "bisect good card".
First, play the "bisect start" card. Then, go to a commit where you don't have the key, and play the "bisect bad" card. Likewise, go to a commit early on where you have the key *in your pocket*, and play the "bisect good" card.
After you've found the last good commit, reset the main branch to it. What happened to the key after you lost it?

View file

@ -5,9 +5,17 @@ cards = checkout commit-auto merge reset-hard
One of your colleagues messed up here, and put the branches in the wrong timelines!
You could delete and re-create these branches - but you can also directly move them to different commits, using `git reset --hard`.
You could delete and re-create these branches - but you can also directly move them to different commits, by using
The donut branch is in the right place, but the timeline is still incomplete.
git checkout
on the branch names, and then using
git reset --hard
on the commit where you want the branch to be.
The donut branch is in the right place, but the timeline is still incomplete - make you actually *eat* the donut in that branch!
[setup]

View file

@ -71,7 +71,7 @@ git commit -am "Put on shirt"
[win]
# Reorder the commits to dress yourself in the correct way
{ git log main --oneline | grep -Pz "shoes[\s\S]*pants[\s\S]*underwear"; } && { test "$(git log main --oneline | wc -l)" -eq 5; }
{ git log main --oneline | perl -0777 -ne'exit(1) if not /shoes[\s\S]*pants[\s\S]*underwear/'; } && { test "$(git log main --oneline | wc -l)" -eq 5; }
[congrats]

View file

@ -9,7 +9,7 @@ you see that their colors match the color of your bed!
Build up your two pieces of furniture by playing the touch card.
Then name your furniture - you can choose whatever you like.
Make sure the colors match! You can find the bed's color in it's description.
Make sure the colors match! You can find the bed's color in its description.
Don't forget to add a color and description to your new furnitures, too!
[setup]

View file

@ -35,4 +35,4 @@ test "$(git show main^:c)" != "c"
[congrats]
Well done! Try tavelling between the commits using `git checkout`, so you can look at their contents again!
Well done! Try travelling between the commits using `git checkout`, so you can look at their contents again!

View file

@ -9,7 +9,8 @@ Have a look at these two timelines. They have exactly the same outcome. But one
[win]
Right! Having each change in its own commit makes it easier to understand what's going on! Let's learn how to do that!
# Right! Having each change in its own commit makes it easier to understand what's going on! Let's learn how to do that!
git branch --show-current | grep step-by-step
[setup]
@ -46,5 +47,5 @@ git checkout HEAD~3
[win]
# Pick the timeline that's clearer, and make the next logical change!
git show step-by-step:smoke_detector | grep -v "absolutely silent"
# Pick the timeline that's clearer, and make the alarm go off!
git show step-by-step:smoke_detector | tail -n 1 | grep -v "absolutely silent"

View file

@ -74,6 +74,9 @@ git branch -D main
# Build a situation where you consumed a baguette, a coffee, *and* a donut.
{ git show HEAD:you | grep "You ate.*baguette"; } && { git show HEAD:you | grep "You drank.*coffee"; } && { git show HEAD:you | grep "You ate.*donut"; }
# Be on a merge commit.
test "$(git log --pretty=%P -n 1 HEAD | wc -w)" -ge 2
[congrats]
I wonder if you're more relaxed when you *sleep* in parallel timelines...

View file

@ -30,4 +30,4 @@ test "$(git status -s)" = ""
[win friend]
# Look at your friend's suggestion, make a compromise, and push it back.
git show main:file | grep green && git show main:file | grep blue || git show main:file | grep turquoise
git rev-parse main^ && test "$(git rev-parse main^1^)" = "$(git rev-parse main^2^)"

View file

@ -3,7 +3,7 @@ cards = checkout commit-auto pull fetch push
[description]
Here's a sandbox with a remote! Try pulling, fetching, or pulling!
Here's a sandbox with a remote! Try pulling, fetching, or pushing!
How can you push tags and branches on a remote? How can you delete them again?

View file

@ -4,7 +4,7 @@ cards = checkout commit-auto merge reset-hard
[description]
You will encounter situations in which you are working on your project but you need to
put your current changes aride temporarily. To do so, you can use the stash function. Use
put your current changes aside temporarily. To do so, you can use the stash function. Use
git stash push
to add your current changes to the stash stack.

View file

@ -11,7 +11,7 @@ Oh, you don't want to keep your stashed changes? There are way too many? Then go
If you only want to discard a certain stash entry, you can use
git stash drop <stash>
Clear you stash stack!
Clear your stash stack!
---
tipp1

View file

@ -39,7 +39,7 @@ git add recipe
[win]
# Did you resolve the confict and commit?
# Did you resolve the conflict and commit?
{ git show HEAD | grep "Flour"; } && { git show HEAD | grep "Salt"; }
# Did you clear stash stack?

View file

@ -17,7 +17,7 @@ You can also sync
git fetch <remote> --prune --prune-tags
Add a tag names "v2" to the last commit and push it to the remote. Also pull the v1 tag to your local repository.
Add a tag named "v2" to the last commit and push it to the remote. Also pull the v1 tag to your local repository.
[setup yours]
git checkout main

View file

@ -3,7 +3,8 @@ cards = clone commit-auto reset-hard checkout file-new branch
[description]
Your friend has a problem! Clone the repo, create a branch called "solution", and fix the problem in this branch. When you're ready, make a "Pull Request" by using `git tag pr`.
Your friend has a problem! Clone the repo located in `../friend`, create a branch called "solution", and fix the problem in this branch. When you're ready, make a "Pull Request" by using `git tag pr`.
[setup]

View file

@ -107,7 +107,7 @@
{
"id": "revert",
"command": "git revert [commit]",
"description": "Make a new commit that reverts the changes of the speicified commit."
"description": "Make a new commit that reverts the changes of the specified commit."
},
{
"id": "bisect-start",
@ -157,7 +157,7 @@
{
"id": "reflog",
"command": "git reflog [ref, head]",
"description": "Display a log of there the ref pointed to in the past."
"description": "Display a log of where the ref pointed to in the past."
},
{
"id": "file-new",

View file

@ -74,7 +74,7 @@ func shell_received(text):
func _notification(what):
if what == MainLoop.NOTIFICATION_WM_QUIT_REQUEST:
#get_tree().quit() # default behavio
#get_tree().quit() # default behavior
get_tree().change_scene("res://scenes/survey.tscn")

View file

@ -86,21 +86,15 @@ func parse_args():
return arguments
func careful_delete(path_inside):
var expected_prefix
var expected_prefix = "%s/tmp/" % OS.get_user_data_dir()
var os = OS.get_name()
if os == "X11":
expected_prefix = "/home/%s/.local/share/Oh My Git/tmp/" % OS.get_environment("USER")
elif os == "OSX":
expected_prefix = "/Users/%s/Library/Application Support/Oh My Git/tmp/" % OS.get_environment("USER")
elif os == "Windows":
expected_prefix = "C:/Users/%s/AppData/Roaming/Oh My Git/tmp/" % OS.get_environment("USERNAME")
if os == "Windows":
# In the game, we use forward slashes:
expected_prefix = expected_prefix.replace("\\", "/")
# Windows treats paths case-insensitively:
expected_prefix = expected_prefix.to_lower()
path_inside = path_inside.to_lower()
else:
helpers.crash("Unsupported OS: %s" % os)
if path_inside.substr(0,expected_prefix.length()) != expected_prefix:
helpers.crash("Refusing to delete directory %s that does not start with %s" % [path_inside, expected_prefix])

View file

@ -34,12 +34,12 @@ while(true) {
STDOUT->flush();
$s = "";
$command = $s2 . "\necho MAGIC\n";
$command = $s2 . "\necho -e \"\\v\"\n";
print $in $command;
inner_while: while (true) {
$line = <$out>;
if ($line eq "MAGIC\n") {
if ($line =~ s/\cK//) {
STDOUT->flush();
last inner_while;
}