Skip to content

Commit

Permalink
Remove Swift Warning Run Script
Browse files Browse the repository at this point in the history
With Xcode 10 we can now simply use #warning("")
  • Loading branch information
bryanluby committed Oct 25, 2018
1 parent 151333f commit a464dbe
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 43 deletions.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,6 @@ You can then delete the `MoveToNonUITestTarget` from the filesystem as the test

- The build phase that runs the [R.swift](https://github.com/mac-cain13/R.swift) script needs to be moved, since it cannot be positioned properly in the template. In the Build Phases for the main target, drag *R.swift Generation Script* up in the list so that it's right above *Compile Sources*

- Note that there's a build-time script to throw compiler warnings whenever you've added a `//WARN:` comment, similar to how `#warning` is used in Obj-C. Find and delete any warnings from this method.

- There are a couple scripts which are included at the base project level which default to generating Objective-C code. In order to generate Swift files for DevsJustWantToHaveFun, you will need to update the scripts to use `swift` instead of `objc` for the `LANGUAGE` option. These scripts can be found in the `[project]/Scripts` folder.

### 5. For All Projects
Expand Down
3 changes: 1 addition & 2 deletions Vokal-Swift.xctemplate/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
import UIKit

class AppDelegate: UIResponder, UIApplicationDelegate {

var window: UIWindow?

//WARN: Did you read the instructions? :D
#warning("Did you read the instructions? :D")
}
21 changes: 0 additions & 21 deletions Vokal-Swift.xctemplate/Scripts/Swift_Warning_Run_Script.sh

This file was deleted.

18 changes: 0 additions & 18 deletions Vokal-Swift.xctemplate/TemplateInfo.plist
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,6 @@
<key>ShellScript</key>
<string>&quot;${SRCROOT}/___PACKAGENAME___/Scripts/R.swift.sh&quot;</string>
</dict>
<dict>
<key>Class</key>
<string>ShellScript</string>
<key>Name</key>
<string>Swift Warning Run Script</string>
<key>ShellPath</key>
<string>/bin/bash</string>
<key>ShellScript</key>
<string>&quot;${SRCROOT}/___PACKAGENAME___/Scripts/Swift_Warning_Run_Script.sh&quot;</string>
</dict>
<dict>
<key>Class</key>
<string>ShellScript</string>
Expand Down Expand Up @@ -120,7 +110,6 @@
<string>../Podfile:swiftbasics</string>
<string>Utilities/DLog.swift</string>
<string>../.swiftlint.yml</string>
<string>Scripts/Swift_Warning_Run_Script.sh</string>
<string>Scripts/R.swift.sh</string>
</array>
<key>Definitions</key>
Expand Down Expand Up @@ -303,13 +292,6 @@
<key>Group</key>
<string>Scripts</string>
</dict>
<key>Scripts/Swift_Warning_Run_Script.sh</key>
<dict>
<key>Path</key>
<string>Scripts/Swift_Warning_Run_Script.sh</string>
<key>Group</key>
<string>Scripts</string>
</dict>
</dict>
<key>Project</key>
<dict>
Expand Down

0 comments on commit a464dbe

Please sign in to comment.