From e6f4b6c286897b2753953d5e27da774ac1dcdb10 Mon Sep 17 00:00:00 2001 From: John Bryan Sazon Date: Fri, 27 Apr 2018 22:09:37 +0800 Subject: [PATCH] Write the ipa link to ipalink.txt file --- cmd/nexus.go | 8 +++++++- ipalink.txt | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 ipalink.txt diff --git a/cmd/nexus.go b/cmd/nexus.go index a203294..db1bcb3 100644 --- a/cmd/nexus.go +++ b/cmd/nexus.go @@ -41,12 +41,18 @@ var nexusCmd = &cobra.Command{ } for _, v := range assets { log.Println("file uploaded:", v) - // write the index.html file (the ota link) to a file + // write the index.html file (the ota link) to a file to gotalink.txt if strings.Contains(v, "index.html") { if err := ioutil.WriteFile("gotalink.txt", []byte(v), 0644); err != nil { log.Fatal(err) } } + // write the ipa download link to a file ipalink.txt + if strings.Contains(v, ".ipa") { + if err := ioutil.WriteFile("ipalink.txt", []byte(v), 0644); err != nil { + log.Fatal(err) + } + } } }, } diff --git a/ipalink.txt b/ipalink.txt new file mode 100644 index 0000000..c763a5f --- /dev/null +++ b/ipalink.txt @@ -0,0 +1 @@ +http://localhost:8081/repository/site/testing/1.0.0/4/sample.ipa \ No newline at end of file