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

fix: remove source & target. and add branch. #5

Merged
merged 2 commits into from
May 31, 2022

Conversation

0x01toby
Copy link
Contributor

@0x01toby 0x01toby commented May 7, 2022

  • DRONE_COMMIT_SOURCE
  • DRONE_COMMIT_TARGET

can not found in https://docs.drone.io/pipeline/environment/reference/

#4

@bradrydzewski
Copy link
Member

Thanks, you are correct that these values do not exist. I think the solution would be to the following change:

	Commit struct {
		Rev     string `envconfig:"DRONE_COMMIT_SHA"`
		Before  string `envconfig:"DRONE_COMMIT_BEFORE"`
		After   string `envconfig:"DRONE_COMMIT_AFTER"`
		Ref     string `envconfig:"DRONE_COMMIT_REF"`
		Branch  string `envconfig:"DRONE_COMMIT_BRANCH"`
-		Source  string `envconfig:"DRONE_COMMIT_SOURCE"`
-		Target  string `envconfig:"DRONE_COMMIT_TARGET"`
+		Source  string `envconfig:"DRONE_SOURCE_BRANCH"`
+		Target  string `envconfig:"DRONE_TARGET_BRANCH"`

https://github.com/drone/drone-jira/blob/master/plugin/pipeline.go#L43:L44

@0x01toby
Copy link
Contributor Author

0x01toby commented May 8, 2022

you are right. I update it.

@tphoney tphoney added the bug Something isn't working label May 31, 2022
@tphoney tphoney merged commit 69025a8 into drone:master May 31, 2022
@tphoney
Copy link
Contributor

tphoney commented May 31, 2022

Thanks for the fix @taorzhang

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants