Skip to content

Conversation

@mattcen
Copy link

@mattcen mattcen commented Mar 20, 2023

Fixes #307

@mattcen
Copy link
Author

mattcen commented Mar 20, 2023

Not sure if this is t he nicest way to do things, especially with the decode() and calling head() just so we can catch it if it fails, but it feels less bad than guessing, which is what this replaces. Thoughts and comments welcome.

@jelmer
Copy link
Contributor

jelmer commented Mar 20, 2023

Rather than checking the revision that HEAD and other branches point at, you could simply check what HEAD resolves to.

See Repo.refs.follow(b'HEAD')

@mattcen
Copy link
Author

mattcen commented Mar 23, 2023

@jelmer Thanks; code updated.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Browsing to a repo shows the most recently updated branch, rather than the default

2 participants