-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9745972
commit 8cbfb3b
Showing
47 changed files
with
2,510 additions
and
1,084 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
4.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
language: objective-c | ||
osx_image: xcode9 | ||
branches: | ||
only: | ||
- master | ||
env: | ||
global: | ||
- LC_CTYPE=en_US.UTF-8 | ||
- LANG=en_US.UTF-8 | ||
- WORKSPACE=OML10n.xcworkspace | ||
- IOS_FRAMEWORK_SCHEME="OML10n" | ||
- EXAMPLE_SCHEME="Example" | ||
matrix: | ||
- DESTINATION="OS=11.0,name=iPhone X" SCHEME="$IOS_FRAMEWORK_SCHEME" RUN_TESTS="NO" BUILD_EXAMPLE="YES" POD_LINT="YES" | ||
- DESTINATION="OS=10.3.1,name=iPhone 7 Plus" SCHEME="$IOS_FRAMEWORK_SCHEME" RUN_TESTS="NO" BUILD_EXAMPLE="YES" POD_LINT="NO" | ||
- DESTINATION="OS=9.0,name=iPhone 6" SCHEME="$IOS_FRAMEWORK_SCHEME" RUN_TESTS="NO" BUILD_EXAMPLE="YES" POD_LINT="NO" | ||
|
||
before_install: | ||
- gem install cocoapods --pre --no-rdoc --no-ri --no-document --quiet | ||
- pod repo update | ||
|
||
script: | ||
- set -o pipefail | ||
- xcodebuild -version | ||
- xcodebuild -showsdks | ||
|
||
# Build Framework in Debug and Run Tests if specified | ||
- if [ $RUN_TESTS == "YES" ]; then | ||
xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty; | ||
else | ||
xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty; | ||
fi | ||
|
||
# Build Framework in Release and Run Tests if specified | ||
- if [ $RUN_TESTS == "YES" ]; then | ||
xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty; | ||
else | ||
xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO build | xcpretty; | ||
fi | ||
|
||
# Build Example in Debug if specified | ||
- if [ $BUILD_EXAMPLE == "YES" ]; then | ||
xcodebuild -workspace "$WORKSPACE" -scheme "$EXAMPLE_SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty; | ||
fi | ||
|
||
# Run `pod lib lint` if specified | ||
- if [ $POD_LINT == "YES" ]; then | ||
pod lib lint; | ||
fi | ||
|
||
after_success: | ||
- bash <(curl -s https://codecov.io/bash) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
source 'https://github.com/CocoaPods/Specs.git' | ||
platform :ios, '9.0' | ||
use_frameworks! | ||
|
||
target 'Example' do | ||
pod 'OML10n', :git => "https://github.com/OnMap/OML10n-iOS.git" | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"info" : { | ||
"version" : 1, | ||
"author" : "xcode" | ||
} | ||
} |
21 changes: 21 additions & 0 deletions
21
Example/Resources/Assets.xcassets/Default-568h.imageset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"images" : [ | ||
{ | ||
"idiom" : "universal", | ||
"scale" : "1x" | ||
}, | ||
{ | ||
"idiom" : "universal", | ||
"filename" : "Default-568h@2x.png", | ||
"scale" : "2x" | ||
}, | ||
{ | ||
"idiom" : "universal", | ||
"scale" : "3x" | ||
} | ||
], | ||
"info" : { | ||
"version" : 1, | ||
"author" : "xcode" | ||
} | ||
} |
Binary file added
BIN
+18.2 KB
Example/Resources/Assets.xcassets/Default-568h.imageset/Default-568h@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Large diffs are not rendered by default.
Oops, something went wrong.
5 changes: 3 additions & 2 deletions
5
...lizationTest/en.lproj/Localizable.strings → ...le/Resources/en.lproj/Localizable.strings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
/* | ||
Localizable.strings | ||
LocalizationTest | ||
LocalizationExample | ||
|
||
Created by Alex Alexandrovych on 16/08/2017. | ||
Copyright © 2017 Alex Alexandrovych. All rights reserved. | ||
*/ | ||
|
||
"Main.Label" = ""; | ||
"Main.CodeLabel" = "english text"; | ||
"Main.ChangeLanguageButton.Normal" = "normal bla button"; |
5 changes: 3 additions & 2 deletions
5
...zationTest/Base.lproj/Localizable.strings → ...le/Resources/he.lproj/Localizable.strings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
/* | ||
Localizable.strings | ||
LocalizationTest | ||
LocalizationExample | ||
|
||
Created by Alex Alexandrovych on 16/08/2017. | ||
Copyright © 2017 Alex Alexandrovych. All rights reserved. | ||
*/ | ||
|
||
"Main.Label" = "text"; | ||
"Main.CodeLabel" = "hebrew text"; | ||
"Main.ChangeLanguageButton.Normal" = "normal bla button"; |
6 changes: 4 additions & 2 deletions
6
...lizationTest/ru.lproj/Localizable.strings → ...le/Resources/ru.lproj/Localizable.strings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
/* | ||
Localizable.strings | ||
LocalizationTest | ||
LocalizationExample | ||
|
||
Created by Alex Alexandrovych on 16/08/2017. | ||
Copyright © 2017 Alex Alexandrovych. All rights reserved. | ||
*/ | ||
"Main.Label" = "russian text"; | ||
|
||
"Main.CodeLabel" = "russian text"; | ||
"Main.ChangeLanguageButton.Normal" = "normal bla button"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
LocalizationTest/LanguageSelectVC.swift → Example/Source/LanguageSelectVC.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 4 additions & 2 deletions
6
...lizationTest/he.lproj/Localizable.strings → Example/Source/Localizable.strings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
/* | ||
Localizable.strings | ||
LocalizationTest | ||
LocalizationExample | ||
|
||
Created by Alex Alexandrovych on 16/08/2017. | ||
Copyright © 2017 Alex Alexandrovych. All rights reserved. | ||
*/ | ||
"Main.Label" = "hebrew text"; | ||
|
||
"Main.CodeLabel" = "english text"; | ||
"Main.ChangeLanguageButton.Normal" = "normal bla button"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
// | ||
// MainVC.swift | ||
// LocalizationExample | ||
// | ||
// Created by Alex Alexandrovych on 16/08/2017. | ||
// Copyright © 2017 Alex Alexandrovych. All rights reserved. | ||
// | ||
|
||
import UIKit | ||
import RxSwift | ||
import OML10n | ||
|
||
class MainVC: UIViewController { | ||
|
||
// MARK: - Properties | ||
|
||
@IBOutlet private weak var storyboardLabel: UILabel! | ||
|
||
private lazy var codeLabel: UILabel = { | ||
let label = UILabel() | ||
label.text = "I'm a button created programmatically" | ||
label.localizationKey = "Main.CodeLabel" | ||
label.textAlignment = .center | ||
label.translatesAutoresizingMaskIntoConstraints = false | ||
return label | ||
}() | ||
|
||
// MARK: - Life cycle | ||
|
||
override func viewDidLoad() { | ||
super.viewDidLoad() | ||
view.addSubview(codeLabel) | ||
NSLayoutConstraint.activate([ | ||
codeLabel.centerXAnchor.constraint(equalTo: view.centerXAnchor), | ||
codeLabel.topAnchor.constraint(equalTo: storyboardLabel.bottomAnchor, constant: 50) | ||
]) | ||
|
||
LiveUpdates.listenUpdates(for: self) | ||
} | ||
|
||
} | ||
|
Oops, something went wrong.