Skip to content

Conversation

@TheMythologist
Copy link
Contributor

Exercise Review

Exercise Discussion

#108

Checklist

  • If you require a new remote repository on the Git-Mastery organization, have you created a request for it?
  • Have you written unit tests using repo-smith to validate the exercise grading scheme?
  • Have you tested the download script using test-download.sh?
  • Have you verified that this exercise does not already exist or is not currently in review?
  • Did you introduce a new grading mechanism that should belong to git-autograder?
  • Did you introduce a new dependency that should belong to app?

Copy link
Member

@woojiahao woojiahao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is pending comments from @damithc but I think we won't need to fork the repository

Comment on lines 14 to 17
"""
hp-force-push (T4L5)
- Fork https://github.com/git-mastery/samplerepo-things to user account as "samplerepo-things-force-push"
- Clone the fork locally as 'samplerepo-things'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't need this comment

Comment on lines 20 to 22
gh_username = run_command(["gh", "api", "user", "-q", ".login"], verbose)
if not gh_username:
raise RuntimeError("Your Github CLI is not setup correctly")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what __requires_github__ does, so this is not necessary

Comment on lines +29 to +43
run_command(
[
"gh",
"repo",
"fork",
UPSTREAM_REPO,
"--default-branch-only",
"--fork-name",
REPO_NAME,
"--clone=true",
"--",
WORK_DIR,
],
verbose,
)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is pending comments from @damithc on the original hands-on discussion, but I don't think we need to fork the repository, cloning using git should be sufficient

Comment on lines 45 to 46
if not work_dir.is_dir():
raise RuntimeError("Fork/clone failed")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

run_command would already catch if the command errors out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants