Skip to content

[New Command Request] Add an option to pull from origin only, ignoring upstream #92

@physcrowley

Description

@physcrowley

Is your feature request related to a problem? Please describe.
see #77

This is to avoid the error message:

failed to run gh: can't sync because there are diverging changes; use `--force` to overwrite the destination branch. error: exit status 1

when student repos aren't in sync with upstream (and may not need to be).

Describe the solution you'd like
As well as the current gh classroom pull student-repos command, a version including the -o flag so the execution is equivalent to git pull origin main instead of the default behaviour (which considers the entire fork chain, i.e. both origin and upstream).

Either:

gh classroom pull -o student-repos

or

gh classroom pull student-repos -o

Describe alternatives you've considered
I've both reverted to my pre-gh classroom scripts and to iterating with a simple shell script through the clones in the x-submissions directory to run git pull origin main.

Additional context
Add any other context or screenshots about the feature request here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions