Skip to content
This repository has been archived by the owner on Oct 4, 2020. It is now read-only.

Fix import bug: add aws and delete nifcloud #17

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

Conversation

donkomura
Copy link

issue

  • computing/computingifaceをインポートするとgo vetで以下のようなエラーが発生
../../go/pkg/mod/github.com/aokumasan/[email protected]/service/computing/computingiface/interface.go:14:2: imported and not used: "github.com/aokumasan/nifcloud-sdk-go-v2/nifcloud"
../../go/pkg/mod/github.com/aokumasan/[email protected]/service/computing/computingiface/interface.go:487:82: undefined: aws
../../go/pkg/mod/github.com/aokumasan/[email protected]/service/computing/computingiface/interface.go:489:81: undefined: aws
../../go/pkg/mod/github.com/aokumasan/[email protected]/service/computing/computingiface/interface.go:491:82: undefined: aws
../../go/pkg/mod/github.com/aokumasan/[email protected]/service/computing/computingiface/interface.go:493:82: undefined: aws

変更内容

  • service/computing/computingiface/interface.goを生成するスクリプトを変更
  • go run private/model/cli/mod-apimain.go --path service/computing/computingiface/interface.goを実行

@@ -123,7 +123,7 @@ func rewriteServiceFile(path string) error {
func rewriteInterfaceFile(path string) error {
serviceName := filepath.Base(filepath.Dir(filepath.Dir(path)))
imports := []map[string]string{
{"github.com/aws/aws-sdk-go-v2/aws": "github.com/aokumasan/nifcloud-sdk-go-v2/nifcloud"},
Copy link
Owner

Choose a reason for hiding this comment

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

github.com/aws/aws-sdk-go-v2/awsgithub.com/aokumasan/nifcloud-sdk-go-v2/nifcloud への書き換えが不要なように見えるので、この行を削除するだけで良さそうです。

また、コードの生成は make コマンドで可能なので、すべてのファイルを生成し直してコミットしていただけると助かります。

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants