Skip to content
This repository has been archived by the owner on Sep 21, 2023. It is now read-only.

update all dependencies #46

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@
.glide/

bin/
.idea/
Copy link
Contributor

Choose a reason for hiding this comment

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

This is for some editor files?

Copy link
Author

Choose a reason for hiding this comment

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

Yes. I use IntelliJ which creates editor files under that directory.

issue-sync
Copy link
Contributor

Choose a reason for hiding this comment

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

Hmm this should not be here. All binaries should be compiles directly in `bin. If not, we have some build system bug

Copy link
Author

Choose a reason for hiding this comment

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

yea it currently builds in the same directory as source. I can look into that. I'll remove this from the pr.

55 changes: 28 additions & 27 deletions glide.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions lib/clients/jira.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ func getErrorBody(config cfg.Config, res *jira.Response) error {
// as well as swap in other implementations, such as for dry run
// or test mocking.
type JIRAClient interface {
ListIssues(ids []int) ([]jira.Issue, error)
ListIssues(ids []int64) ([]jira.Issue, error)
GetIssue(key string) (jira.Issue, error)
CreateIssue(issue jira.Issue) (jira.Issue, error)
UpdateIssue(issue jira.Issue) (jira.Issue, error)
Expand Down Expand Up @@ -112,7 +112,7 @@ type realJIRAClient struct {
// ListIssues returns a list of JIRA issues on the configured project which
// have GitHub IDs in the provided list. `ids` should be a comma-separated
// list of GitHub IDs.
func (j realJIRAClient) ListIssues(ids []int) ([]jira.Issue, error) {
func (j realJIRAClient) ListIssues(ids []int64) ([]jira.Issue, error) {
log := j.config.GetLogger()

idStrs := make([]string, len(ids))
Expand Down Expand Up @@ -399,7 +399,7 @@ func truncate(s string, length int) string {
// list of GitHub IDs.
//
// This function is identical to that in realJIRAClient.
func (j dryrunJIRAClient) ListIssues(ids []int) ([]jira.Issue, error) {
func (j dryrunJIRAClient) ListIssues(ids []int64) ([]jira.Issue, error) {
log := j.config.GetLogger()

idStrs := make([]string, len(ids))
Expand Down
2 changes: 1 addition & 1 deletion lib/comments.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ func CompareComments(config cfg.Config, ghIssue github.Issue, jIssue jira.Issue,
}
// matches[0] is the whole string, matches[1] is the ID
matches := jCommentIDRegex.FindStringSubmatch(jComment.Body)
id, _ := strconv.Atoi(matches[1])
id, _ := strconv.ParseInt(matches[1], 10, 64)
Copy link
Contributor

Choose a reason for hiding this comment

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

Not from this PR,but we need to give this module some TLC and check all returned errors.

Copy link
Author

Choose a reason for hiding this comment

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

Yep. My upcoming PRs add features as well as more thorough error handling and I'm currently working on unit tests. It might prove difficult to slice the upcoming work into small PRs (I'll do my best obviously) but included in those changes are some minor improvements in various parts of the code.

if *ghComment.ID != id {
continue
}
Expand Down
2 changes: 1 addition & 1 deletion lib/issues.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func CompareIssues(config cfg.Config, ghClient clients.GitHubClient, jiraClient
return nil
}

ids := make([]int, len(ghIssues))
ids := make([]int64, len(ghIssues))
for i, v := range ghIssues {
ids[i] = v.GetID()
}
Expand Down
3 changes: 3 additions & 0 deletions vendor/github.com/andygrunwald/go-jira/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions vendor/github.com/andygrunwald/go-jira/.travis.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

36 changes: 36 additions & 0 deletions vendor/github.com/andygrunwald/go-jira/Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

46 changes: 46 additions & 0 deletions vendor/github.com/andygrunwald/go-jira/Gopkg.toml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading