-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcheckpoint.yaml
84 lines (77 loc) · 2.38 KB
/
checkpoint.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
uuid: 07173abe-b9d9-4b8a-94f6-6b6ded343882
title: Git Basics Tutorial
topic: Version Control
tags:
- git
- terminal
image:
registry: andylizf
name: git-tutorial
base: ubuntu:22.04
runtime:
program: bash
program_args: []
packages:
- git
- nano
- openssh-client
setup_commands:
- git config --global user.email "[email protected]"
- git config --global user.name "Student"
- git config --global init.defaultBranch main
- mkdir -p ~/workspace
- cd ~/workspace
flags:
- title: Initialize Git Repository
prompt: "Mission 1: Create Your First Git Repository"
description: |
Let's start by creating a new Git repository:
1. Use 'git init' to initialize a new repository
2. This will create a hidden .git directory to store your repository data
listener:
target: output
type: regex
match: "(?s).*Initialized empty Git repository in .*/\\.git.*"
- title: Create and Add Files
prompt: "Mission 2: Stage Your First Changes"
description: |
Now let's create and stage some files:
1. Use 'echo "Hello, Git!" > hello.txt' to create a new file
2. Use 'git add hello.txt' to stage the file
listener:
target: command
type: exact
match: "git add hello.txt"
- title: Make Your First Commit
prompt: "Mission 3: Commit Your Changes"
description: |
Time to commit your changes:
1. Use 'git commit -m "Initial commit"'
2. This will create a permanent record of your changes
listener:
target: output
type: regex
match: "\\[main .+\\] Initial commit"
files: []
- title: Check Repository Status
prompt: "Mission 4: View Repository Status"
description: |
Let's check the status of your repository:
1. Use 'git status' to see the current state
2. You should see that everything is up to date
listener:
target: output
type: regex
match: "On branch main\\nnothing to commit, working tree clean"
files: []
- title: View Commit History
prompt: "Mission 5: View Git Log"
description: |
Finally, let's look at your commit history:
1. Use 'git log' to see your commits
2. You should see your initial commit
listener:
target: output
type: regex
match: "commit\\s+[a-f0-9]+.*\\nAuthor:\\s+Student\\s+<student@example\\.com>\\n.*\\n\\s*Initial commit"
files: []