mirror of
https://github.com/git-learning-game/oh-my-git.git
synced 2024-11-13 19:04:54 +01:00
Display a nice error screen if Git is not installed
This commit is contained in:
parent
5b590b8367
commit
2fc78f3e99
1 changed files with 9 additions and 5 deletions
|
@ -23,6 +23,10 @@ func _ready():
|
||||||
|
|
||||||
global_shell = Shell.new()
|
global_shell = Shell.new()
|
||||||
|
|
||||||
|
if global_shell.run("command -v git &>/dev/null && echo yes || echo no") == "no\n":
|
||||||
|
game.skipped_title = true
|
||||||
|
get_tree().change_scene("res://scenes/no_git.tscn")
|
||||||
|
else:
|
||||||
create_file_in_game_env(".gitconfig", helpers.read_file("res://scripts/gitconfig"))
|
create_file_in_game_env(".gitconfig", helpers.read_file("res://scripts/gitconfig"))
|
||||||
|
|
||||||
copy_script_to_game_env("fake-editor")
|
copy_script_to_game_env("fake-editor")
|
||||||
|
|
Loading…
Reference in a new issue