Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include https:// in PR link #148

Closed

Conversation

This allows terminals to make it highlighted and clicky.

commit-id:ec630215
@@ -167,7 +167,7 @@ func (pr *PullRequest) String(config *config.Config) string {

prInfo := fmt.Sprintf("%3d", pr.Number)
if config.User.ShowPRLink {
prInfo = fmt.Sprintf("%s/%s/%s/pull/%d",
prInfo = fmt.Sprintf("https://%s/%s/%s/pull/%d",
Copy link
Owner

Choose a reason for hiding this comment

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

my terminal actually highlights without the https, and I don't want to make the lines even longer.
instead of changing this here, will changing the githubHost in your spr.yml and adding a https:// prefix there work?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I tried Alacritty, Kitty, urxvt, Gnome Terminal, Terminator and none of them had clicky links without the prefix. It seems your terminal would be the exception?

Copy link
Owner

Choose a reason for hiding this comment

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

I use iTerm.
But regardless, does updating your value of githubHost in the configuration file work for you?

Copy link
Collaborator Author

@leoluk leoluk Dec 13, 2021

Choose a reason for hiding this comment

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

No, it breaks the logic that finds the access token from the config file.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Either way I think we should pick a default that works in terminals that aren't iTerm - it's the only one I could find that highlights schema-less URLs

@leoluk leoluk changed the base branch from pr/leoluk/develop/bdba0972 to master December 13, 2021 13:05
@leoluk leoluk changed the base branch from master to pr/leoluk/develop/bdba0972 December 13, 2021 13:05
@leoluk
Copy link
Collaborator Author

leoluk commented Dec 18, 2021

✓ Commit merged in pull request #156

@leoluk leoluk closed this Dec 18, 2021
@leoluk leoluk deleted the pr/leoluk/develop/ec630215 branch December 18, 2021 11:40
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.

2 participants