From 60288d221ce923239a78d43bf6605119210cf762 Mon Sep 17 00:00:00 2001 From: fnaoto Date: Mon, 28 Dec 2020 11:44:01 +0900 Subject: [PATCH 1/4] Fix Member struct for organization member. --- deploygate_organization_member.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploygate_organization_member.go b/deploygate_organization_member.go index 584b329..431e8c2 100644 --- a/deploygate_organization_member.go +++ b/deploygate_organization_member.go @@ -15,7 +15,7 @@ type Member struct { UserName string `mapstructure:"username"` Email string `mapstructure:"email"` IconURL string `mapstructure:"icon_url"` - Inviting bool `mapstructure:"inviting"` + Type string `mapstructure:"type"` } func (c *Client) GetOrganizationMember(i *GetOrganizationMemberInput) (*GetOrganizationMemberResponse, error) { From 4e137c1c0edc5cf84bdec0bdd85e09f89f187b18 Mon Sep 17 00:00:00 2001 From: fnaoto Date: Mon, 28 Dec 2020 11:56:07 +0900 Subject: [PATCH 2/4] Add inviting response. --- deploygate_organization_member.go | 1 + 1 file changed, 1 insertion(+) diff --git a/deploygate_organization_member.go b/deploygate_organization_member.go index 431e8c2..325e9ac 100644 --- a/deploygate_organization_member.go +++ b/deploygate_organization_member.go @@ -16,6 +16,7 @@ type Member struct { Email string `mapstructure:"email"` IconURL string `mapstructure:"icon_url"` Type string `mapstructure:"type"` + Inviting bool `mapstructure:"inviting"` } func (c *Client) GetOrganizationMember(i *GetOrganizationMemberInput) (*GetOrganizationMemberResponse, error) { From d28b0fd05b45a98cf98f1caa602f7bd964d44c6e Mon Sep 17 00:00:00 2001 From: fnaoto Date: Mon, 28 Dec 2020 11:56:20 +0900 Subject: [PATCH 3/4] Add go module. --- .gitignore | 2 +- go.mod | 11 +++++++++++ go.sum | 10 ++++++++++ vendor/vendor.json | 43 ------------------------------------------- 4 files changed, 22 insertions(+), 44 deletions(-) create mode 100644 go.mod create mode 100644 go.sum delete mode 100644 vendor/vendor.json diff --git a/.gitignore b/.gitignore index 96773af..b093787 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ -vendor/*/ +vendor/* .DS_STORE diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..47c98cc --- /dev/null +++ b/go.mod @@ -0,0 +1,11 @@ +module github.com/recruit-mp/go-deploygate + +go 1.15 + +require ( + github.com/ajg/form v0.0.0-20160822230020-523a5da1a92f + github.com/dnaeon/go-vcr v0.0.0-20161028051908-82c8877b5545 + github.com/hashicorp/go-cleanhttp v0.0.0-20160407174126-ad28ea4487f0 + github.com/mitchellh/mapstructure v0.0.0-20161020161836-f3009df150da + gopkg.in/yaml.v2 v2.0.0-20160928153709-a5b47d31c556 // indirect +) diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..dabedb1 --- /dev/null +++ b/go.sum @@ -0,0 +1,10 @@ +github.com/ajg/form v0.0.0-20160822230020-523a5da1a92f h1:zvClvFQwU++UpIUBGC8YmDlfhUrweEy1R1Fj1gu5iIM= +github.com/ajg/form v0.0.0-20160822230020-523a5da1a92f/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= +github.com/dnaeon/go-vcr v0.0.0-20161028051908-82c8877b5545 h1:COwH5cas0KkEZwN4EIkt6gt4BJRf7Ls3r60I6owooys= +github.com/dnaeon/go-vcr v0.0.0-20161028051908-82c8877b5545/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E= +github.com/hashicorp/go-cleanhttp v0.0.0-20160407174126-ad28ea4487f0 h1:2l0haPDqCzZEO160UR5DSrrl8RWptFCoxFsSbRLJBaI= +github.com/hashicorp/go-cleanhttp v0.0.0-20160407174126-ad28ea4487f0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= +github.com/mitchellh/mapstructure v0.0.0-20161020161836-f3009df150da h1:z1HPq7I0Eajh3On8i7MEfqOurIg+aCllNR3omoF2UNY= +github.com/mitchellh/mapstructure v0.0.0-20161020161836-f3009df150da/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +gopkg.in/yaml.v2 v2.0.0-20160928153709-a5b47d31c556 h1:hKXbLW5oaJoQgs8KrzTLdF4PoHi+0oQPgea9TNtvE3E= +gopkg.in/yaml.v2 v2.0.0-20160928153709-a5b47d31c556/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= diff --git a/vendor/vendor.json b/vendor/vendor.json deleted file mode 100644 index 3940163..0000000 --- a/vendor/vendor.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "comment": "", - "ignore": "test", - "package": [ - { - "checksumSHA1": "kMfAFLobZymMrCOm/Xi/g9gnJOU=", - "path": "github.com/ajg/form", - "revision": "523a5da1a92f01b01f840b61689c0340a0243532", - "revisionTime": "2016-08-22T23:00:20Z" - }, - { - "checksumSHA1": "RaHOSsDNtJOKQuQknteuD0nhHOA=", - "path": "github.com/dnaeon/go-vcr/cassette", - "revision": "82c8877b55452fe358f69d77685e57700f78c30a", - "revisionTime": "2016-10-28T05:19:08Z" - }, - { - "checksumSHA1": "h9b/qZp03YOZpQj0bK7hdoTXwmA=", - "path": "github.com/dnaeon/go-vcr/recorder", - "revision": "82c8877b55452fe358f69d77685e57700f78c30a", - "revisionTime": "2016-10-28T05:19:08Z" - }, - { - "checksumSHA1": "Uzyon2091lmwacNsl1hCytjhHtg=", - "path": "github.com/hashicorp/go-cleanhttp", - "revision": "ad28ea4487f05916463e2423a55166280e8254b5", - "revisionTime": "2016-04-07T17:41:26Z" - }, - { - "checksumSHA1": "UuXgD2dDojfS8AViUEe15gLIWZE=", - "path": "github.com/mitchellh/mapstructure", - "revision": "f3009df150dadf309fdee4a54ed65c124afad715", - "revisionTime": "2016-10-20T16:18:36Z" - }, - { - "checksumSHA1": "12GqsW8PiRPnezDDy0v4brZrndM=", - "path": "gopkg.in/yaml.v2", - "revision": "a5b47d31c556af34a302ce5d659e6fea44d90de0", - "revisionTime": "2016-09-28T15:37:09Z" - } - ], - "rootPath": "github.com/recruit-mp/go-deploygate" -} From f2870c1c48b9f54c322a5e3829c7e321d3e96267 Mon Sep 17 00:00:00 2001 From: fnaoto Date: Mon, 28 Dec 2020 12:26:06 +0900 Subject: [PATCH 4/4] Add member type of name, type and url. --- deploygate_organization_member.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deploygate_organization_member.go b/deploygate_organization_member.go index 325e9ac..a72af74 100644 --- a/deploygate_organization_member.go +++ b/deploygate_organization_member.go @@ -12,8 +12,8 @@ type GetOrganizationMemberResponse struct { } type Member struct { - UserName string `mapstructure:"username"` - Email string `mapstructure:"email"` + Name string `mapstructure:"name"` + URL string `mapstructure:"url"` IconURL string `mapstructure:"icon_url"` Type string `mapstructure:"type"` Inviting bool `mapstructure:"inviting"`