Skip to content

Commit 17f93da

Browse files
committed
Upgrade the project to use Carthage, Alamofire and
Upgrade the project to use Carthage, Alamofire and SwiftyJSON. Also use framework to share code between targets.
1 parent 29d3b33 commit 17f93da

File tree

18 files changed

+770
-988
lines changed

18 files changed

+770
-988
lines changed

Podfile

-2
This file was deleted.

Podfile.lock

-30
This file was deleted.

README.md

+17-22
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,42 @@
11
Swift Weather
22
============
33

4-
SwiftWeather is an iOS weather app developed in Swift language. The app can support iPhone 4(s), iPhone 5(s), iPhone 6 and iPhone 6 Plus.
4+
SwiftWeather is an iOS weather app developed in Swift language. The app can support iPhone 4(s), iPhone 5(s), iPhone 6 and iPhone 6 Plus. The app also support Today Widgets.
5+
6+
7+
## Version 2
8+
This is version 2. I have ugraded the entire project to use [Carthage](https://github.com/Carthage/Carthage), [Alamofire](https://github.com/Alamofire/Alamofire) and [SwiftyJSON](https://github.com/SwiftyJSON/SwiftyJSON). And the app can only support iOS8+, if you want to support iOS7 or use CocoaPods and AFNetworking. Please have a look at [README.v1.md](https://github.com/JakeLin/SwiftWeather/blob/master/README.v1.md) and Release [Using Cocoapods and AFNetworking](https://github.com/JakeLin/SwiftWeather/releases/tag/V1). Happy coding.
59

610
## Screenshots
711
![Loading](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/loading-33.png)
812

913
![Loading](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/6-Today-smallsize.png)
1014

11-
12-
#### iPhone 4s
13-
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/4s-smallsize.png)
14-
15-
#### iPhone 5s
16-
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/5s-smallsize.png)
17-
18-
19-
#### iPhone 6
2015
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/6-smallsize.png)
2116

22-
23-
#### iPhone 6 Plus
24-
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/6plus-smallsize.png)
25-
2617
## Notices
27-
Because Apple keeps changing the Swift compiler, the current version can be compiled in Xcode 6.1.
18+
Because Apple keeps changing the Swift compiler, the current version can be compiled in Xcode 6.2 beta.
2819

2920
## Used features
3021
* Swift Programming Language
31-
* CocoaPods
32-
* AFNetworking
22+
* [Carthage](https://github.com/Carthage/Carthage)
23+
* [Alamofire](https://github.com/Alamofire/Alamofire)
24+
* [SwiftyJSON](https://github.com/SwiftyJSON/SwiftyJSON)
3325
* Core Location
26+
* Using Framework to share code between app and widget.
27+
3428

29+
## Known issus
30+
Because we are using [Carthage](https://github.com/Carthage/Carthage) to build the third party packages. There are some build warings like `ld: warning: linking against dylib not safe for use in application extensions: /Build/Products/Debug-iphoneos/Alamofire.framework/Alamofire`
3531

3632
## How to build
37-
Because the app uses CocoaPods, we need to run `pod install` to install all the pods.
33+
Because the app uses carthage, we need to install carthage. To install the carthage tool on your system, please download and run the Carthage.pkg file for the latest [release](https://github.com/Carthage/Carthage/releases), then follow the on-screen instructions..
3834

3935
1. Open Terminal app.
4036
2. Change directory to the project folder. `cd $project_dir`
41-
3. Use `ls` to list all the file to check whether *Podfile* file is in the folder?
42-
4. If the *Podfile* has been found, then execute `pod install`
43-
5. If the Mac OS doesn't have CocoaPods installed. Please follow [CocoaPods Getting Started](http://guides.cocoapods.org/using/getting-started.html) to install.
44-
6. Once complete installation, open *Swift Weather.xcworkspace* file with Xcode 6.
37+
3. Use `ls` to list all the file to check whether *Cartfile* file is in the folder?
38+
4. If the *Cartfile* has been found, then execute `carthage update`.This will fetch dependencies into a Carthage/Checkouts folder, then build each one.
39+
5. On your application targets’ “General” settings tab, in the “Linked Frameworks and Libraries” section, drag and drop each framework you want to use from the Carthage/Build folder on disk. In our project, which are `Alamofire` and `SwiftyJSON`
4540
7. Press *Cmd + B* to build the app.
4641
8. Press *Cmd + R* to run the app on Simulator.
4742

README.v1.md

+50
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
Swift Weather
2+
============
3+
4+
SwiftWeather is an iOS weather app developed in Swift language. The app can support iPhone 4(s), iPhone 5(s), iPhone 6 and iPhone 6 Plus.
5+
6+
## Screenshots
7+
![Loading](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/loading-33.png)
8+
9+
![Loading](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/6-Today-smallsize.png)
10+
11+
12+
#### iPhone 4s
13+
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/4s-smallsize.png)
14+
15+
#### iPhone 5s
16+
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/5s-smallsize.png)
17+
18+
19+
#### iPhone 6
20+
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/6-smallsize.png)
21+
22+
23+
#### iPhone 6 Plus
24+
![Swift Weather](https://raw.githubusercontent.com/JakeLin/SwiftWeather/master/screenshots/6plus-smallsize.png)
25+
26+
## Notices
27+
Because Apple keeps changing the Swift compiler, the current version can be compiled in Xcode 6.1.
28+
29+
## Used features
30+
* Swift Programming Language
31+
* CocoaPods
32+
* AFNetworking
33+
* Core Location
34+
35+
36+
## How to build
37+
Because the app uses CocoaPods, we need to run `pod install` to install all the pods.
38+
39+
1. Open Terminal app.
40+
2. Change directory to the project folder. `cd $project_dir`
41+
3. Use `ls` to list all the file to check whether *Podfile* file is in the folder?
42+
4. If the *Podfile* has been found, then execute `pod install`
43+
5. If the Mac OS doesn't have CocoaPods installed. Please follow [CocoaPods Getting Started](http://guides.cocoapods.org/using/getting-started.html) to install.
44+
6. Once complete installation, open *Swift Weather.xcworkspace* file with Xcode 6.
45+
7. Press *Cmd + B* to build the app.
46+
8. Press *Cmd + R* to run the app on Simulator.
47+
48+
## Credits
49+
* Thanks to [johnsonjake](https://github.com/johnsonjake) for adding iOS 8 support and improving the UI/UX.
50+
* Thanks to [Marc](https://github.com/gizmou) for adding forcast feature, widget and app icon.

Swift Weather Instant/Swift Weather Instant-Bridging-Header.h

-5
This file was deleted.

0 commit comments

Comments
 (0)