Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Nodes with values to reuse in the pipeline.
common_params:
plugins: &common_plugins
- &bash_cache automattic/bash-cache#2.0.0: ~
# Common environment values to use with the `env` key.
env: &common_env
IMAGE_ID: xcode-13

# This is the default pipeline – it will build and test the app
steps:
#################
# Build and Test
#################
- label: "🔬 Build and Test"
key: "test"
command: |
# See https://github.com/Automattic/bash-cache-buildkite-plugin/issues/16
gem install bundler:2.3.4

build_and_test_pod
env: *common_env
plugins: *common_plugins

#################
# Validate Podspec
#################
- label: "🔬 Validate Podspec"
key: "validate"
command: |
# See https://github.com/Automattic/bash-cache-buildkite-plugin/issues/16
gem install bundler:2.3.4

validate_podspec
env: *common_env
plugins: *common_plugins

#################
# Lint
#################
- label: "🧹 Lint"
key: "lint"
command: |
# See https://github.com/Automattic/bash-cache-buildkite-plugin/issues/16
gem install bundler:2.3.4

lint_pod
env: *common_env
plugins: *common_plugins

#################
# Publish the Podspec (if we're building a tag)
#################
- label: "⬆️ Publish Podspec"
key: "publish"
command: .buildkite/publish-pod.sh
env: *common_env
plugins: *common_plugins
depends_on:
- "test"
- "validate"
- "lint"
if: build.tag != null
agents:
queue: "mac"
20 changes: 20 additions & 0 deletions .buildkite/publish-pod.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/bin/bash -eu

PODSPEC_PATH="MediaEditor.podspec"
SPECS_REPO="git@github.com:wordpress-mobile/cocoapods-specs.git"
SLACK_WEBHOOK=$PODS_SLACK_WEBHOOK

echo "--- :rubygems: Setting up Gems"
# See https://github.com/Automattic/bash-cache-buildkite-plugin/issues/16
gem install bundler:2.3.4

install_gems

echo "--- :cocoapods: Publishing Pod to CocoaPods CDN"
publish_pod $PODSPEC_PATH

echo "--- :cocoapods: Publishing Pod to WP Specs Repo"
publish_private_pod $PODSPEC_PATH $SPECS_REPO "$SPEC_REPO_PUBLIC_DEPLOY_KEY"

echo "--- :slack: Notifying Slack"
slack_notify_pod_published $PODSPEC_PATH $SLACK_WEBHOOK
2 changes: 2 additions & 0 deletions .bundle/config
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
BUNDLE_PATH: "vendor/bundle"
34 changes: 0 additions & 34 deletions .circleci/config.yml

This file was deleted.

3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ build-iPhoneSimulator/
/rdoc/

## Environment normalization:
/.bundle/
/vendor/bundle
/lib/bundler/man/

Expand Down Expand Up @@ -169,7 +168,7 @@ Dependencies/
# screenshots whenever they are needed.
# For more information about the recommended setup visit:
# https://docs.fastlane.tools/best-practices/source-control/#source-control

/fastlane/README.md

# Code Injection
# After new code Injection tools there's a generated folder /iOSInjectionProject
Expand Down
8 changes: 8 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Opt in to new cops by default
AllCops:
NewCops: enable

# Allow the Podspec filename to match the project
Naming/FileName:
Exclude:
- 'MediaEditor.podspec'
1 change: 0 additions & 1 deletion Cartfile

This file was deleted.

1 change: 0 additions & 1 deletion Cartfile.private

This file was deleted.

2 changes: 0 additions & 2 deletions Cartfile.resolved

This file was deleted.

11 changes: 7 additions & 4 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
source 'https://rubygems.org' do
gem 'cocoapods', '~> 1.8.0'
gem 'xcpretty'
end
# frozen_string_literal: true

source 'https://rubygems.org'

gem 'cocoapods', '~> 1.8.0'
gem 'fastlane', '~> 2.189'
gem 'rubocop', '~> 1.18'
Loading