Skip to content

Commit

Permalink
bugfix: chinese disorderly code of displayname
Browse files Browse the repository at this point in the history
  • Loading branch information
Urinx committed Jan 30, 2017
1 parent 311a8d1 commit 6d97cea
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 10 deletions.
Binary file not shown.
27 changes: 17 additions & 10 deletions AppResign/AppResign/main.swift
Original file line number Diff line number Diff line change
Expand Up @@ -30,20 +30,27 @@ func Usage() {
exit(1)
}

// deprecated
//func raw_input(_ prompt: String = "> ") -> String {
// print(prompt, terminator:"")
// var input: String = ""
//
// while true {
// let c = Character(UnicodeScalar(UInt32(fgetc(stdin)))!)
// if c == "\n" {
// return input
// } else {
// input.append(c)
// }
// }
//}

func raw_input(_ prompt: String = "> ") -> String {
print(prompt, terminator:"")
var input: String = ""

while true {
let c = Character(UnicodeScalar(UInt32(fgetc(stdin)))!)
if c == "\n" {
return input
} else {
input.append(c)
}
}
return readLine(strippingNewline: true) ?? ""
}


func mainRoutine(_ input: String, output: String, certificate: String, provProfile: String, bundleId: String, displayName: String) {
let support = ["deb", "ipa", "app", "xcarchive"]
if support.contains(input.pathExtension) {
Expand Down

0 comments on commit 6d97cea

Please sign in to comment.