Skip to content
This repository was archived by the owner on Feb 5, 2025. It is now read-only.

Commit 0f34cd4

Browse files
committed
CircleCI: Simplify config by using shared Orbs for testing the project and validating the podspec
1 parent 272aace commit 0f34cd4

File tree

5 files changed

+30
-35
lines changed

5 files changed

+30
-35
lines changed

.circleci/config.yml

Lines changed: 15 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,17 @@
1-
version: 2
2-
jobs:
3-
build_and_test:
4-
macos:
5-
xcode: "10.1.0"
6-
steps:
7-
- checkout
8-
- restore_cache:
9-
keys:
10-
- wordpress-authenticator-ios-{{ checksum "Gemfile.lock" }}-{{ checksum "Podfile.lock" }}
11-
- run:
12-
name: Bundle install
13-
command: bundle install --path=vendor/bundle
14-
- run:
15-
name: Fetch CocoaPods Specs
16-
command: curl https://cocoapods-specs.circleci.com/fetch-cocoapods-repo-from-s3.sh | bash -s cf
17-
- run:
18-
name: Pod Install
19-
command: bundle exec pod install --repo-update
20-
environment:
21-
COCOAPODS_DISABLE_STATS: true
22-
- save_cache:
23-
key: wordpress-authenticator-ios-{{ checksum "Gemfile.lock" }}-{{ checksum "Podfile.lock" }}
24-
paths:
25-
- Pods/
26-
- vendor/bundle
27-
- run:
28-
name: Test
29-
command: bundle exec pod lib lint
1+
version: 2.1
2+
3+
orbs:
4+
# This uses the iOS Orb located at https://github.com/wordpress-mobile/circleci-orbs
5+
ios: wordpress-mobile/[email protected]
6+
307
workflows:
31-
version: 2
32-
wordpress_ios:
8+
test_and_validate:
339
jobs:
34-
- build_and_test
35-
10+
- ios/test:
11+
name: Test
12+
workspace: WordPressAuthenticator.xcworkspace
13+
scheme: WordPressAuthenticator
14+
destination: "platform=iOS Simulator,name=iPhone XS,OS=latest"
15+
- ios/validate-podspec:
16+
name: Validate Podspec
17+
podspec-path: WordPressAuthenticator.podspec

Gemfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
source 'https://rubygems.org' do
22
gem 'cocoapods', '1.5.3'
3+
gem 'cocoapods-check'
4+
gem 'cocoapods-repo-update'
5+
gem 'xcpretty'
36
end

Gemfile.lock

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ GEM
2828
nap (~> 1.0)
2929
ruby-macho (~> 1.1)
3030
xcodeproj (>= 1.5.7, < 2.0)
31+
cocoapods-check (1.0.2)
32+
cocoapods (~> 1.0)
3133
cocoapods-core (1.5.3)
3234
activesupport (>= 4.0.2, < 6)
3335
fuzzy_match (~> 2.0.4)
@@ -36,6 +38,8 @@ GEM
3638
cocoapods-downloader (1.2.2)
3739
cocoapods-plugins (1.0.0)
3840
nap
41+
cocoapods-repo-update (0.0.4)
42+
cocoapods (~> 1.0, >= 1.3.0)
3943
cocoapods-search (1.0.0)
4044
cocoapods-stats (1.0.0)
4145
cocoapods-trunk (1.3.1)
@@ -55,6 +59,7 @@ GEM
5559
nanaimo (0.2.6)
5660
nap (1.1.0)
5761
netrc (0.11.0)
62+
rouge (2.0.7)
5863
ruby-macho (1.3.1)
5964
thread_safe (0.3.6)
6065
tzinfo (1.2.5)
@@ -65,12 +70,17 @@ GEM
6570
claide (>= 1.0.2, < 2.0)
6671
colored2 (~> 3.1)
6772
nanaimo (~> 0.2.6)
73+
xcpretty (0.3.0)
74+
rouge (~> 2.0.7)
6875

6976
PLATFORMS
7077
ruby
7178

7279
DEPENDENCIES
7380
cocoapods (= 1.5.3)!
81+
cocoapods-check!
82+
cocoapods-repo-update!
83+
xcpretty!
7484

7585
BUNDLED WITH
7686
1.17.2

Podfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ inhibit_all_warnings!
44
use_frameworks!
55

66
platform :ios, '10.0'
7-
7+
plugin 'cocoapods-repo-update'
88

99
## WordPress Authenticator
1010
## =======================

Podfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,6 @@ SPEC CHECKSUMS:
121121
WordPressUI: 44fe43a9c5c504dfd534286e39e1ce6ebcd69ff5
122122
wpxmlrpc: 6ba55c773cfa27083ae4a2173e69b19f46da98e2
123123

124-
PODFILE CHECKSUM: 1b7831d7a214edf6e85e0d3e3ead39484c4058d4
124+
PODFILE CHECKSUM: e3a4b6f748b0b420639d2ee45f7fe40d82bd011d
125125

126126
COCOAPODS: 1.5.3

0 commit comments

Comments
 (0)