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

feat: plugin-add command can take git branch name. #1204

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

vic
Copy link
Contributor

@vic vic commented Apr 15, 2022

Summary

Previously it was only possible to clone plugin repos on their default branch.
This pull-request allows the plugin-add command to take an aditional
argument for specifying a git-ref used for git clone.

Note: The plugin-update command already was able to take a git-ref,
but this feature eliminates the need of doing plugin-add and immediatly
plugin-update just for setting the git-ref to use.

Motivation

Sometimes it's convenient to specify another plugin-repo branch or release-tag,
instead of using the repos' default branch.

For example, if a plugin becomes unstable on its default branch because
a bug was introduced, or if the fix is only available at an experimental
branch, people might want to try those changes.

Also, some advanced plugins, like
asdf-direnv can have
tagged releases or develop branches that can potentially be
more experimental but more feature-forward than the master branch.

Other information

Added a test that exercises clonning using an specific branch name.

Documented on help.txt and had keep all other commands help aligned.

Closes #1201
Closes #166

@vic vic requested a review from a team as a code owner April 15, 2022 19:36
Previously it was only possible to clone plugin repos on their default branch.
This pull-request allows the `plugin-add` command to take an aditional
argument for specifying a git-ref used for `git clone`.

Note: The `plugin-update` command already was able to take a `git-ref`,
but this feature eliminates the need of doing `plugin-add` and immediatly
`plugin-update` just for setting the git-ref to use.

Sometimes it's convenient to specify another plugin-repo branch or release-tag,
instead of using the repos' default branch.

For example, if a plugin becomes unstable on its default branch because
a bug was introduced, or if the fix is only available at an experimental
branch, people might want to try those changes.

Also, some advanced plugins, like
[asdf-direnv](https://github.com/asdf-community/asdf-direnv) can have
tagged releases or `develop` branches that can potentially be
more *experimental* but more feature-forward than the `master` branch.

Added a test that exercises clonning using an specific branch name.

Documented on help.txt and had keep all other commands help aligned.

Closes asdf-vm#1201
Copy link
Contributor

@jthegedus jthegedus left a comment

Choose a reason for hiding this comment

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

LGTM, please just update and resolve conflicts (I would be am not at a machine right now)

@jahands
Copy link

jahands commented May 2, 2023

👀

@aabouzaid
Copy link

What's needed to merge this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority asdf core intend to resolve soon
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support plugin install giturl#gitref Versioning of plugins
4 participants