sheagcraig / yo

Send Notification Center messages from the command line
Apache License 2.0
384 stars 44 forks source link

Won't build in XCode 7.1 #8

Closed charliwest closed 8 years ago

charliwest commented 9 years ago

I built yo previously ok, now my company has rebranded and I need to rebuild it again with the new icon. When I try though xcode throws up lots of errors about various things e.g. '#' has been removed from Swift; double up 'flagIndex flagIndex' to make the argument label the same as the parameter name 'toInt()' is unavailable: Use Int() initializer 'enumerate' is unavailable: call the 'enumerate()' method on the sequence

Am I doing something wrong?

sheagcraig commented 9 years ago

No-it's just not Swift 2.0 compliant yet. That being said, I thought Xcode was supposed to automatically fix stuff like like the enumerate call.

On Mon, Nov 9, 2015 at 4:52 AM, David West notifications@github.com wrote:

I built yo previously ok, now my company has rebranded and I need to rebuild it again with the new icon. When I try though xcode throws up lots of errors about various things e.g. '#' has been removed from Swift; double up 'flagIndex flagIndex' to make the argument label the same as the parameter name 'toInt()' is unavailable: Use Int() initializer 'enumerate' is unavailable: call the 'enumerate()' method on the sequence

Am I doing something wrong?

— Reply to this email directly or view it on GitHub https://github.com/sheagcraig/yo/issues/8.

charliwest commented 8 years ago

OK back from work trip, so update it when I load the project into xcode it offers to convert it, says its done, then the build still fails with the same issues. :( Getting someone with 6 to build it for now.

haircut commented 8 years ago

Automatic syntax conversion seems to work but a problem still exists in line 45 of AppDelegate.swift:

task.arguments = ["-c"] + [bashAction]

Build fails with error "Binary operator '+' cannot be applied to two '[String]' operands"

I tried changing the concatenation to something like task.arguments = "-c \(bashAction)" but I'm so new to Swift it's beyond my depth.

sheagcraig commented 8 years ago

@charliwest and @haircut: Give this a go. It builds... I can't get anything to happen on my laptop, and I'm out of time for testing it right now. Feedback on buildability and whether it actually posts notifications would be helpful-thanks!

sheagcraig commented 8 years ago

@charliwest @haircut I should point out-you need the testing-elcapitan branch!

charliwest commented 8 years ago

Worked for me! Still gave 1 error "Unable to determine compiler to use - the abstract compiler specification is missing from this Xcode installation." on the yoTests And 2 warnings "warning: no rule to process file '/Users/User/yo/CHANGELOG.md' of type net.daringfireball.markdown for architecture x86_64 warning: no rule to process file '/Users/User/yo/README.md' of type net.daringfireball.markdown for architecture x86_64" But built, tested and I got notifications with the new logo, thank you! Will test on a couple more users over the week as well.

sheagcraig commented 8 years ago

I think we're good to go on this.