From 5c2f75805318c2028e2723361b5138b0a1a40a15 Mon Sep 17 00:00:00 2001 From: Joe Ferguson Date: Thu, 26 Oct 2017 07:42:49 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20Fix=20typo=20in=20"copyed"=20->?= =?UTF-8?q?=20"copied"=20usages.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- builder/alicloud/ecs/step_region_copy_image.go | 6 +++--- builder/alicloud/ecs/step_share_image.go | 12 ++++++------ post-processor/vagrant/hyperv.go | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/builder/alicloud/ecs/step_region_copy_image.go b/builder/alicloud/ecs/step_region_copy_image.go index 5f60cafab..f92878712 100644 --- a/builder/alicloud/ecs/step_region_copy_image.go +++ b/builder/alicloud/ecs/step_region_copy_image.go @@ -59,11 +59,11 @@ func (s *setpRegionCopyAlicloudImage) Cleanup(state multistep.StateBag) { client := state.Get("client").(*ecs.Client) alicloudImages := state.Get("alicloudimages").(map[string]string) ui.Say(fmt.Sprintf("Stopping copy image because cancellation or error...")) - for copyedRegionId, copyedImageId := range alicloudImages { - if copyedRegionId == s.RegionId { + for copiedRegionId, copiedImageId := range alicloudImages { + if copiedRegionId == s.RegionId { continue } - if err := client.CancelCopyImage(common.Region(copyedRegionId), copyedImageId); err != nil { + if err := client.CancelCopyImage(common.Region(copiedRegionId), copiedImageId); err != nil { ui.Say(fmt.Sprintf("Error cancelling copy image: %v", err)) } } diff --git a/builder/alicloud/ecs/step_share_image.go b/builder/alicloud/ecs/step_share_image.go index bdd8d1245..50e5a640f 100644 --- a/builder/alicloud/ecs/step_share_image.go +++ b/builder/alicloud/ecs/step_share_image.go @@ -19,11 +19,11 @@ func (s *setpShareAlicloudImage) Run(state multistep.StateBag) multistep.StepAct client := state.Get("client").(*ecs.Client) ui := state.Get("ui").(packer.Ui) alicloudImages := state.Get("alicloudimages").(map[string]string) - for copyedRegion, copyedImageId := range alicloudImages { + for copiedRegion, copiedImageId := range alicloudImages { err := client.ModifyImageSharePermission( &ecs.ModifyImageSharePermissionArgs{ - RegionId: common.Region(copyedRegion), - ImageId: copyedImageId, + RegionId: common.Region(copiedRegion), + ImageId: copiedImageId, AddAccount: s.AlicloudImageShareAccounts, RemoveAccount: s.AlicloudImageUNShareAccounts, }) @@ -44,11 +44,11 @@ func (s *setpShareAlicloudImage) Cleanup(state multistep.StateBag) { client := state.Get("client").(*ecs.Client) alicloudImages := state.Get("alicloudimages").(map[string]string) ui.Say("Restoring image share permission because cancellations or error...") - for copyedRegion, copyedImageId := range alicloudImages { + for copiedRegion, copiedImageId := range alicloudImages { err := client.ModifyImageSharePermission( &ecs.ModifyImageSharePermissionArgs{ - RegionId: common.Region(copyedRegion), - ImageId: copyedImageId, + RegionId: common.Region(copiedRegion), + ImageId: copiedImageId, AddAccount: s.AlicloudImageUNShareAccounts, RemoveAccount: s.AlicloudImageShareAccounts, }) diff --git a/post-processor/vagrant/hyperv.go b/post-processor/vagrant/hyperv.go index 14486738b..657304963 100644 --- a/post-processor/vagrant/hyperv.go +++ b/post-processor/vagrant/hyperv.go @@ -68,7 +68,7 @@ func (p *HypervProvider) Process(ui packer.Ui, artifact packer.Artifact, dir str } } - ui.Message(fmt.Sprintf("Copyed %s to %s", path, dstPath)) + ui.Message(fmt.Sprintf("Copied %s to %s", path, dstPath)) } return