Skip to content

Commit

Permalink
fix some bug
Browse files Browse the repository at this point in the history
  • Loading branch information
alanpeng committed Aug 21, 2020
1 parent b3fe8c4 commit 00aaf62
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ download file or transfer docker image from [katacode](https://katacoda.com/cour

# useage:
go get githu.com/xilu0/transfer
transfer --uerser=heishui --password="" --usr=https://golang.google.cn/dl/go1.15.windows-amd64.msi --image=vmware/photon:1.0
transfer --user=heishui --password="" --url=https://golang.google.cn/dl/go1.15.windows-amd64.msi --image=vmware/photon:1.0
3 changes: 2 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ func main() {
}
}
func GetImage(name string) string {
newImage := strings.Split(name, "/")[2]
imageArry := strings.Split(name, "/")
newImage := imageArry[len(imageArry)-1]
newFullImage := registry + "/" + repository + "/" + newImage
return newFullImage
}
Expand Down

0 comments on commit 00aaf62

Please sign in to comment.