Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

Fix glab repo view handling of branches #787

Merged

Conversation

brodock
Copy link
Contributor

@brodock brodock commented Jul 6, 2021

Description
This does fix a few things in glab repo view command:

  1. Uses provided -b branchname to also retrieve the README file.
  2. Only override an empty opts.Branch when a repository is not provided as argument
  3. The generated URL for opening in a browser only appends /-/tree/ when provided branch is not an empty string

Related Issue
Resolves #786

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation
  • Chore (Related to CI or Packaging to platforms)

@codecov
Copy link

codecov bot commented Jul 6, 2021

Codecov Report

Merging #787 (14ba6cf) into trunk (8bd042a) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##            trunk     #787   +/-   ##
=======================================
  Coverage   58.34%   58.34%           
=======================================
  Files          93       93           
  Lines        6696     6696           
=======================================
  Hits         3907     3907           
  Misses       2409     2409           
  Partials      380      380           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8bd042a...14ba6cf. Read the comment docs.

@profclems profclems merged commit b6c9163 into profclems:trunk Jul 11, 2021
@brodock brodock deleted the brodock/fix-repo-view-branch-argument branch July 22, 2021 17:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

glab repo view has issues detecting and handling branches
2 participants