-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from Tangem/CSS-127
CSS-127
- Loading branch information
Showing
9 changed files
with
461 additions
and
2 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,2 @@ | ||
fastlane/** linguist-vendored | ||
TangemSdk/TangemSdk/Crypto/secp256k1/** linguist-vendored |
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,34 @@ | ||
name: Create release branch | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
versionName: | ||
description: 'Name of version (ie 1.3.0)' | ||
required: true | ||
|
||
jobs: | ||
createrelease: | ||
name: Create release branch | ||
runs-on: ubuntu-latest | ||
#if: contains(github.ref, 'develop') # Only for develop branch | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Create release branch | ||
run: git checkout -b release/v${{ github.event.inputs.versionName }} | ||
|
||
- name: Initialize mandatory git config | ||
run: | | ||
git config user.name "Tangem Bot" | ||
git config user.email [email protected] | ||
- name: Change version | ||
run: | | ||
echo ${{ github.event.inputs.versionName }} > VERSION | ||
git add VERSION | ||
git commit -m "Prepare release v${{ github.event.inputs.versionName }}" | ||
- name: Push new branch | ||
run: git push origin release/v${{ github.event.inputs.versionName }} |
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 @@ | ||
name: Neutral Build Tag | ||
|
||
on: | ||
push: | ||
branches: [ develop ] | ||
|
||
env: | ||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} | ||
|
||
jobs: | ||
tag: | ||
name: Create tag | ||
runs-on: macOS-latest | ||
steps: | ||
- name: Extract branch name | ||
shell: bash | ||
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" | ||
id: extract_branch | ||
|
||
- name: Create tag | ||
uses: actions/github-script@v3 | ||
with: | ||
github-token: ${{ github.token }} | ||
script: | | ||
github.git.createRef({ | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
ref: "refs/tags/${{ steps.extract_branch.outputs.branch }}-${{ github.run_number }}", | ||
sha: context.sha | ||
}) | ||
- name: Build notification | ||
if: always() | ||
uses: adamkdean/simple-slack-notify@master | ||
with: | ||
channel: '#development-ios' | ||
status: ${{ job.status }} | ||
success_text: 'Neutral build #${{ github.run_number }} completed successfully. Tag has been created.' | ||
failure_text: 'GitHub Action #${{ github.run_number }} failed. Tag has not been not created.' | ||
cancelled_text: 'GitHub Action #${{ github.run_number }} was cancelled' | ||
fields: | | ||
[{"title": "TAG", "value": "${{ steps.extract_branch.outputs.branch }}-${{ github.run_number }}"}, | ||
{"title": "Action URL", "value": "${env.GITHUB_SERVER_URL}/${env.GITHUB_REPOSITORY}/actions/runs/${env.GITHUB_RUN_ID}"}] |
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,32 @@ | ||
name: Neutral Build | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- 'release/**' | ||
- 'develop' | ||
workflow_dispatch: | ||
|
||
env: | ||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_DVELOPMENT_IOS }} | ||
|
||
jobs: | ||
test: | ||
name: Test | ||
runs-on: macOS-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Bundle Install | ||
run: bundle install | ||
- name: Tests | ||
run: bundle exec fastlane test | ||
- name: Build notification | ||
if: failure() | ||
uses: adamkdean/simple-slack-notify@master | ||
with: | ||
channel: '#development-ios' | ||
text: 'Neutral build #${{ github.run_number }} failed' | ||
color: 'danger' | ||
fields: | | ||
[{ "title": "Action URL", "value": "${env.GITHUB_SERVER_URL}/${env.GITHUB_REPOSITORY}/actions/runs/${env.GITHUB_RUN_ID}"}] |
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,49 @@ | ||
name: Publish Release | ||
|
||
on: | ||
#push: | ||
# branches: [ master ] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
merges: | ||
name: Publish release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out | ||
uses: actions/checkout@v2 | ||
|
||
- name: Bundle Install | ||
run: bundle install | ||
|
||
- name: Prepare variables | ||
run: | | ||
VER=$(cat VERSION) | ||
echo "VERSION=$VER" >> $GITHUB_ENV | ||
- name: Create a release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token | ||
with: | ||
tag_name: v${{ env.VERSION }} | ||
release_name: Release v${{ env.VERSION }} | ||
commitish: release/v${{ env.VERSION }} | ||
draft: false | ||
prerelease: false | ||
|
||
- name: Bump version in podspec | ||
run: fastlane run version_bump_podspec path:"TangemSdk.podspec" version_number:${{ env.VERSION }} | ||
|
||
- name: Create pull request to develop | ||
uses: actions/github-script@v3 | ||
with: | ||
github-token: ${{ github.token }} | ||
script: | | ||
github.git.createPullRequest({ | ||
owner: 'context.repo.owner', | ||
repo: 'context.repo.repo', | ||
title: 'Release v${{ github.event.inputs.versionName }}', | ||
head: 'release/v${{ github.event.inputs.versionName }}', | ||
base: 'develop' | ||
}) |
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 @@ | ||
source "https://rubygems.org" | ||
|
||
gem "fastlane" | ||
gem "cocoapods" |
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 was deleted.
Oops, something went wrong.
Oops, something went wrong.