Commit 120ecee4 authored by Andreas Traczyk's avatar Andreas Traczyk

build: fastlane setup

- Adds a configuration called 'Development' to the project, which uses
  manual signing

- Changes the 'Release' configuration to use manual signing

- Adds support for fastlane automation.
  This commit adds 2 lanes:

  - 'test' uses scan to build and run unit tests on the client

  - 'build' unlocks the system's keychain, uses match to sync the
    development certificate and provisioning profile with a private git
    repo, then uses gym to build the development configuration of the
    xcode project

- Adds a .gitignore to Ring/fastlane for undesired fastlane related files

Change-Id: I1bc0eb8cfa20cc536c297ba7ae14292cc66e1d96
parent 2d64729d
......@@ -1210,7 +1210,7 @@
TargetAttributes = {
043999F21D1C2D9D00E99CD9 = {
CreatedOnToolsVersion = 7.3.1;
DevelopmentTeam = KM95526DS8;
DevelopmentTeam = MSHYCBXK85;
LastSwiftMigration = 0810;
ProvisioningStyle = Automatic;
SystemCapabilities = {
......@@ -1222,11 +1222,13 @@
04399A0B1D1C2D9D00E99CD9 = {
CreatedOnToolsVersion = 7.3.1;
LastSwiftMigration = 0810;
ProvisioningStyle = Automatic;
TestTargetID = 043999F21D1C2D9D00E99CD9;
};
04399A161D1C2D9D00E99CD9 = {
CreatedOnToolsVersion = 7.3.1;
LastSwiftMigration = 0810;
ProvisioningStyle = Automatic;
TestTargetID = 043999F21D1C2D9D00E99CD9;
};
};
......@@ -1629,7 +1631,7 @@
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KM95526DS8;
DEVELOPMENT_TEAM = MSHYCBXK85;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Carthage/Build/iOS",
......@@ -1659,10 +1661,10 @@
CLANG_CXX_LANGUAGE_STANDARD = "c++14";
CLANG_CXX_LIBRARY = "compiler-default";
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KM95526DS8;
CODE_SIGN_IDENTITY = "iPhone Distribution";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
DEVELOPMENT_TEAM = "";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Carthage/Build/iOS",
......@@ -1748,6 +1750,120 @@
};
name = Release;
};
6229B5A51FCDB006006937DF /* Development */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.3;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Development;
};
6229B5A61FCDB006006937DF /* Development */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_CXX_LANGUAGE_STANDARD = "c++14";
CLANG_CXX_LIBRARY = "compiler-default";
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Manual;
DEVELOPMENT_TEAM = "";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Carthage/Build/iOS",
);
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Ring/RingPrefixHeader.pch;
HEADER_SEARCH_PATHS = "$(SRCROOT)/../fat/include";
INFOPLIST_FILE = Ring/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.3;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
LIBRARY_SEARCH_PATHS = "$(SRCROOT)/../fat/lib";
PRODUCT_BUNDLE_IDENTIFIER = com.savoirfairelinux.ring;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "";
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_OBJC_BRIDGING_HEADER = "Ring/Bridging/Ring-Bridging-Header.h";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 3.0;
VALID_ARCHS = arm64;
};
name = Development;
};
6229B5A71FCDB006006937DF /* Development */ = {
isa = XCBuildConfiguration;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Carthage/Build/iOS",
);
HEADER_SEARCH_PATHS = "$(SRCROOT)/../fat/include";
INFOPLIST_FILE = RingTests/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
LIBRARY_SEARCH_PATHS = "$(SRCROOT)/../fat/lib";
PRODUCT_BUNDLE_IDENTIFIER = cx.ring.RingTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "RingTests/RingTests-Bridging-Header.h";
SWIFT_VERSION = 3.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Ring.app/Ring";
};
name = Development;
};
6229B5A81FCDB006006937DF /* Development */ = {
isa = XCBuildConfiguration;
buildSettings = {
INFOPLIST_FILE = RingUITests/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = cx.ring.RingUITest;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
TEST_TARGET_NAME = Ring;
};
name = Development;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
......@@ -1755,6 +1871,7 @@
isa = XCConfigurationList;
buildConfigurations = (
04399A1E1D1C2D9D00E99CD9 /* Debug */,
6229B5A51FCDB006006937DF /* Development */,
04399A1F1D1C2D9D00E99CD9 /* Release */,
);
defaultConfigurationIsVisible = 0;
......@@ -1764,6 +1881,7 @@
isa = XCConfigurationList;
buildConfigurations = (
04399A211D1C2D9D00E99CD9 /* Debug */,
6229B5A61FCDB006006937DF /* Development */,
04399A221D1C2D9D00E99CD9 /* Release */,
);
defaultConfigurationIsVisible = 0;
......@@ -1773,6 +1891,7 @@
isa = XCConfigurationList;
buildConfigurations = (
04399A241D1C2D9D00E99CD9 /* Debug */,
6229B5A71FCDB006006937DF /* Development */,
04399A251D1C2D9D00E99CD9 /* Release */,
);
defaultConfigurationIsVisible = 0;
......@@ -1782,6 +1901,7 @@
isa = XCConfigurationList;
buildConfigurations = (
04399A271D1C2D9D00E99CD9 /* Debug */,
6229B5A81FCDB006006937DF /* Development */,
04399A281D1C2D9D00E99CD9 /* Release */,
);
defaultConfigurationIsVisible = 0;
......
report.xml
test_output/
app_identifier "com.savoirfairelinux.ring" # The bundle identifier of your app
apple_id "mobile@savoirfairelinux.com" # Your Apple email address
team_id "MSHYCBXK85" # Developer Portal Team ID
# you can even provide different app identifiers, Apple IDs and team names per lane:
# More information: https://docs.fastlane.tools/advanced/#appfile
# Customise this file, documentation can be found here:
# https://github.com/fastlane/fastlane/tree/master/fastlane/docs
# All available actions: https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Actions.md
# can also be listed using the `fastlane actions` command
# Change the syntax highlighting to Ruby
# All lines starting with a # are ignored when running `fastlane`
# If you want to automatically update fastlane if a new version is available:
# update_fastlane
# This is the minimum version number required.
# Update this, if you use features of a newer version
fastlane_version "2.68.0"
default_platform :ios
platform :ios do
desc "Runs all the tests"
lane :test do
scan
end
desc "Test build without packaging"
lane :build do
unlock_keychain
match(
force: true,
type: "development"
)
gym(
scheme: "Ring",
clean: true,
configuration: "Development",
export_method: 'development',
skip_package_ipa: true
)
end
after_all do |lane|
# This block is called, only if the executed lane was successful
end
error do |lane, exception|
# This block is called, only if the executed lane has failed
end
end
fastlane documentation
================
# Installation
Make sure you have the latest version of the Xcode command line tools installed:
```
xcode-select --install
```
## Choose your installation method:
<table width="100%" >
<tr>
<th width="33%"><a href="http://brew.sh">Homebrew</a></th>
<th width="33%">Installer Script</th>
<th width="33%">RubyGems</th>
</tr>
<tr>
<td width="33%" align="center">macOS</td>
<td width="33%" align="center">macOS</td>
<td width="33%" align="center">macOS or Linux with Ruby 2.0.0 or above</td>
</tr>
<tr>
<td width="33%"><code>brew cask install fastlane</code></td>
<td width="33%"><a href="https://download.fastlane.tools">Download the zip file</a>. Then double click on the <code>install</code> script (or run it in a terminal window).</td>
<td width="33%"><code>sudo gem install fastlane -NV</code></td>
</tr>
</table>
# Available Actions
## iOS
### ios test
```
fastlane ios test
```
Runs all the tests
### ios build
```
fastlane ios build
```
Test build without packaging
----
This README.md is auto-generated and will be re-generated every time [fastlane](https://fastlane.tools) is run.
More information about fastlane can be found on [fastlane.tools](https://fastlane.tools).
The documentation of fastlane can be found on [docs.fastlane.tools](https://docs.fastlane.tools).
{
"CARTOON_FANTASY_VIOLENCE": 0,
"REALISTIC_VIOLENCE": 0,
"PROLONGED_GRAPHIC_SADISTIC_REALISTIC_VIOLENCE": 0,
"PROFANITY_CRUDE_HUMOR": 0,
"MATURE_SUGGESTIVE": 0,
"HORROR": 0,
"MEDICAL_TREATMENT_INFO": 0,
"ALCOHOL_TOBACCO_DRUGS": 0,
"GAMBLING": 0,
"SEXUAL_CONTENT_NUDITY": 0,
"GRAPHIC_SEXUAL_CONTENT_NUDITY": 0,
"UNRESTRICTED_WEB_ACCESS": 0,
"GAMBLING_CONTESTS": 0
}
Put all screenshots you want to use inside the folder of its language (e.g. en-US).
The device type will automatically be recognized using the image resolution. Apple TV screenshots
should be stored in a subdirectory named appleTV with language folders inside of it. iMessage
screenshots, like Apple TV screenshots, should also be stored in a subdirectory named iMessage
with language folders inside of it.
The screenshots can be named whatever you want, but keep in mind they are sorted alphabetically.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment