Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions exercise_utils/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ def __init__(self, repo: Repo, verbose: bool) -> None:
def create_start_tag(self) -> None:
# TODO: Reconsider if this should be inlined within repo-smith or separated out
"""Creates the Git-Mastery start tag."""
assert self.repo is not None
all_commits = list(self.repo.iter_commits())
first_commit = list(reversed(all_commits))[0]
first_commit_hash = first_commit.hexsha[:7]
Expand Down
7 changes: 5 additions & 2 deletions hands_on/move_tags.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import os
from exercise_utils.git import tag_with_options
from exercise_utils.git import (
tag,
tag_with_options,
)
from exercise_utils.github_cli import (
get_github_username,
has_repo,
Expand Down Expand Up @@ -27,5 +30,5 @@ def download(verbose: bool):
clone_repo_with_gh(full_repo_name, verbose)

os.chdir(LOCAL_DIR)
tag_with_options("v1.0", ["HEAD~1"], verbose)
tag("v1.0", verbose)
tag_with_options("v0.9", ["HEAD~2", "-a", "-m", "First beta release"], verbose)
4 changes: 3 additions & 1 deletion sensors_checkout/.gitmastery-exercise.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
],
"requires_git": true,
"requires_github": true,
"base_files": {},
"base_files": {
"answers.txt": "answers.txt"
},
"exercise_repo": {
"repo_type": "remote",
"repo_name": "sensors",
Expand Down
5 changes: 5 additions & 0 deletions sensors_diff/res/answers.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,14 @@ A:

Q: Which are the new values in modified but unstaged files?
A:
- ans1
- ans2

Q: Which files have changed from Jan 09th to Jan 15th?
A:
- ans1
- ans2
- ans3

Q: Which new values are new in north.csv on Jan 10th, compared to Jan 01st?
A:
2 changes: 1 addition & 1 deletion sensors_diff/res/north.csv
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
5789
6940
1235
8890
8890
2 changes: 1 addition & 1 deletion sensors_diff/res/south.csv
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
8745
4069
1592
6831
6831
4 changes: 2 additions & 2 deletions view_commits/verify.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@

QUESTION_ONE = "In February, who was replaced in the Wednesday duty roster?"
QUESTION_TWO = "In February, who joined the Tuesday duty roster?"
QUESTION_THREE = "In April, what were the new names added to the duty rosters? Give the list of names as one line, separated by spaces."
QUESTION_FOUR = "In January, who were in the Tuesday duty roster? Give the list of names as one line, separated by spaces."
QUESTION_THREE = "In April, what were the new names added to the duty rosters? Remove/add extra rows where appropriate."
QUESTION_FOUR = "In January, who were in the Tuesday duty roster? Remove/add extra rows where appropriate."


def verify(exercise: GitAutograderExercise) -> GitAutograderOutput:
Expand Down