Skip to content

Commit 077fb8f

Browse files
Git action folder added
1 parent 0037956 commit 077fb8f

File tree

10 files changed

+454
-0
lines changed

10 files changed

+454
-0
lines changed

.github/ISSUE_TEMPLATE/BUG-REPORT.yml

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
name: 🐞 Bug
2+
description: File a bug/issue
3+
title: "[BUG] <title>"
4+
labels: ["bug", "needs-triage"]
5+
body:
6+
- type: checkboxes
7+
attributes:
8+
label: Is there an existing issue for this?
9+
description: Please search to see if an issue already exists for the bug you encountered.
10+
options:
11+
- label: I have searched the existing issues
12+
required: true
13+
- type: textarea
14+
attributes:
15+
label: SDK Version
16+
description: Version of the SDK in use?
17+
validations:
18+
required: true
19+
- type: textarea
20+
attributes:
21+
label: iOS Version
22+
description: Version of iOS in use?
23+
validations:
24+
required: true
25+
- type: textarea
26+
attributes:
27+
label: Current Behavior
28+
description: A concise description of what you're experiencing.
29+
validations:
30+
required: true
31+
- type: textarea
32+
attributes:
33+
label: Expected Behavior
34+
description: A concise description of what you expected to happen.
35+
validations:
36+
required: true
37+
- type: textarea
38+
attributes:
39+
label: Steps To Reproduce
40+
description: Steps to reproduce the behavior.
41+
placeholder: |
42+
1. In this environment...
43+
1. With this config...
44+
1. Run '...'
45+
1. See error...
46+
validations:
47+
required: true
48+
- type: textarea
49+
attributes:
50+
label: Link
51+
description: Link to code demonstrating the problem.
52+
validations:
53+
required: false
54+
- type: textarea
55+
attributes:
56+
label: Logs / Stacktraces
57+
description: Logs/stack traces related to the problem (⚠️do not include sensitive information).
58+
validations:
59+
required: false
60+
- type: dropdown
61+
attributes:
62+
label: Severity
63+
description: What is the severity of the problem?
64+
multiple: true
65+
options:
66+
- Blocking development
67+
- Affecting users
68+
- Minor issue
69+
validations:
70+
required: false
71+
- type: textarea
72+
attributes:
73+
label: Workaround/Solution
74+
description: Do you have any workaround or solution in mind for the problem?
75+
validations:
76+
required: false
77+
- type: textarea
78+
attributes:
79+
label: "Recent Change"
80+
description: Has this issue started happening after an update or experiment change?
81+
validations:
82+
required: false
83+
- type: textarea
84+
attributes:
85+
label: Conflicts
86+
description: Are there other libraries/dependencies potentially in conflict?
87+
validations:
88+
required: false
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: ✨Enhancement
2+
description: Create a new ticket for a Enhancement/Tech-initiative for the benefit of the SDK which would be considered for a minor version update.
3+
title: "[ENHANCEMENT] <title>"
4+
labels: ["enhancement"]
5+
body:
6+
- type: textarea
7+
id: description
8+
attributes:
9+
label: "Description"
10+
description: Briefly describe the enhancement in a few sentences.
11+
placeholder: Short description...
12+
validations:
13+
required: true
14+
- type: textarea
15+
id: benefits
16+
attributes:
17+
label: "Benefits"
18+
description: How would the enhancement benefit to your product or usage?
19+
placeholder: Benefits...
20+
validations:
21+
required: true
22+
- type: textarea
23+
id: detail
24+
attributes:
25+
label: "Detail"
26+
description: How would you like the enhancement to work? Please provide as much detail as possible
27+
placeholder: Detailed description...
28+
validations:
29+
required: false
30+
- type: textarea
31+
id: examples
32+
attributes:
33+
label: "Examples"
34+
description: Are there any examples of this enhancement in other products/services? If so, please provide links or references.
35+
placeholder: Links/References...
36+
validations:
37+
required: false
38+
- type: textarea
39+
id: risks
40+
attributes:
41+
label: "Risks/Downsides"
42+
description: Do you think this enhancement could have any potential downsides or risks?
43+
placeholder: Risks/Downsides...
44+
validations:
45+
required: false
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<!--
2+
Thanks for filing in issue! Are you requesting a new feature? If so, please share your feedback with us on the following link.
3+
-->
4+
## Feedback requesting a new feature can be shared [here.](https://feedback.optimizely.com/)

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: 💡Feature Requests
4+
url: https://feedback.optimizely.com/
5+
about: Feedback requesting a new feature can be shared here.
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Reusable action of Integration tests
2+
3+
on:
4+
workflow_call:
5+
secrets:
6+
CI_USER_TOKEN:
7+
required: true
8+
TRAVIS_COM_TOKEN:
9+
required: true
10+
11+
jobs:
12+
integration_tests:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v3
16+
with:
17+
# You should create a personal access token and store it in your repository
18+
token: ${{ secrets.CI_USER_TOKEN }}
19+
repository: 'optimizely/travisci-tools'
20+
path: 'home/runner/travisci-tools'
21+
ref: 'master'
22+
- name: set SDK Branch if PR
23+
if: ${{ github.event_name == 'pull_request' }}
24+
run: |
25+
echo "SDK_BRANCH=${{ github.head_ref }}" >> $GITHUB_ENV
26+
- name: set SDK Branch if not pull request
27+
if: ${{ github.event_name != 'pull_request' }}
28+
run: |
29+
echo "SDK_BRANCH=${{ github.ref_name }}" >> $GITHUB_ENV
30+
echo "TRAVIS_BRANCH=${{ github.ref_name }}" >> $GITHUB_ENV
31+
- name: Trigger build
32+
env:
33+
SDK: swift
34+
TESTAPP_TAG: master
35+
BUILD_NUMBER: ${{ github.run_id }}
36+
TESTAPP_BRANCH: master
37+
GITHUB_TOKEN: ${{ secrets.CI_USER_TOKEN }}
38+
EVENT_TYPE: ${{ github.event_name }}
39+
GITHUB_CONTEXT: ${{ toJson(github) }}
40+
#REPO_SLUG: ${{ github.repository }}
41+
PULL_REQUEST_SLUG: ${{ github.repository }}
42+
UPSTREAM_REPO: ${{ github.repository }}
43+
PULL_REQUEST_SHA: ${{ github.event.pull_request.head.sha }}
44+
PULL_REQUEST_NUMBER: ${{ github.event.pull_request.number }}
45+
UPSTREAM_SHA: ${{ github.sha }}
46+
TOKEN: ${{ secrets.TRAVIS_COM_TOKEN }}
47+
EVENT_MESSAGE: ${{ github.event.message }}
48+
HOME: 'home/runner'
49+
run: |
50+
home/runner/travisci-tools/trigger-script-with-status-update.sh

.github/workflows/lint_markdown.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Reusable action of linting markdown files
2+
3+
on: [workflow_call]
4+
5+
jobs:
6+
lint_markdown:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v3
10+
- name: Set up Ruby
11+
uses: ruby/setup-ruby@v1
12+
with:
13+
ruby-version: '2.6'
14+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
15+
- name: Install gem and Run tests
16+
run: |
17+
cd ../../
18+
gem install awesome_bot
19+
find . -type f -name '*.md' -exec awesome_bot {} \;
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Source clear
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
schedule:
7+
# Runs "weekly"
8+
- cron: '0 0 * * 0'
9+
10+
jobs:
11+
source_clear:
12+
runs-on: macos-12
13+
steps:
14+
- uses: actions/checkout@v3
15+
- name: Source clear scan
16+
env:
17+
SRCCLR_API_TOKEN: ${{ secrets.SRCCLR_API_TOKEN }}
18+
run: |
19+
gem install cocoapods -v '1.9.3'
20+
curl -sSL https://download.sourceclear.com/ci.sh | bash -s - scan

.github/workflows/swift.yml

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
name: Swift
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
workflow_dispatch:
9+
inputs:
10+
PREP:
11+
required: false
12+
type: boolean
13+
description: prepare to release
14+
RELEASE:
15+
required: false
16+
type: boolean
17+
description: release
18+
19+
env:
20+
VERSION: 4.0.0-beta
21+
22+
jobs:
23+
24+
lint_markdown_files:
25+
uses: optimizely/swift-sdk/.github/workflows/lint_markdown.yml@master
26+
27+
integration_tests:
28+
if: "${{ github.event.inputs.PREP == '' && github.event.inputs.RELEASE == '' }}"
29+
uses: optimizely/swift-sdk/.github/workflows/integration_tests.yml@master
30+
secrets:
31+
CI_USER_TOKEN: ${{ secrets.CI_USER_TOKEN }}
32+
TRAVIS_COM_TOKEN: ${{ secrets.TRAVIS_COM_TOKEN }}
33+
34+
lint:
35+
runs-on: macos-12
36+
steps:
37+
- uses: actions/checkout@v3
38+
- uses: maxim-lobanov/setup-xcode@v1
39+
with:
40+
xcode-version: 14.1.0
41+
- env:
42+
SRCCLR_API_TOKEN: ${{ secrets.SRCCLR_API_TOKEN }}
43+
run: |
44+
gem install cocoapods -v '1.9.3'
45+
pod spec lint --quick
46+
curl -sSL https://download.sourceclear.com/ci.sh | bash
47+
48+
unittests:
49+
if: "${{ github.event.inputs.PREP == '' && github.event.inputs.RELEASE == '' }}"
50+
uses: optimizely/swift-sdk/.github/workflows/unit_tests.yml@master
51+
52+
prepare_for_release:
53+
runs-on: macos-12
54+
if: "${{ github.event.inputs.PREP == 'true' && github.event_name == 'workflow_dispatch' }}"
55+
steps:
56+
- uses: actions/checkout@v3
57+
- uses: maxim-lobanov/setup-xcode@v1
58+
with:
59+
xcode-version: 14.1.0
60+
- id: prepare_for_release
61+
name: Prepare for release
62+
env:
63+
HOME: 'home/runner'
64+
REPO_SLUG: ${{ github.repository }}
65+
BRANCH: ${{ github.ref_name }}
66+
GITHUB_USER: optibot
67+
GITHUB_TOKEN: ${{ secrets.CI_USER_TOKEN }}
68+
COCOAPODS_VERSION: '1.12.1'
69+
run: |
70+
gem install cocoapods -v $COCOAPODS_VERSION
71+
Scripts/run_prep.sh
72+
- name: Check prepare for release failure
73+
if: steps.prepare_for_release.conclusion == 'failure'
74+
run: cat /tmp/build.out
75+
76+
release:
77+
if: "${{github.event.inputs.RELEASE == 'true' && github.event_name == 'workflow_dispatch' }}"
78+
runs-on: macos-12
79+
steps:
80+
- uses: actions/checkout@v3
81+
- uses: maxim-lobanov/setup-xcode@v1
82+
with:
83+
xcode-version: 14.1.0
84+
- name: Push to cocoapods.org
85+
env:
86+
HOME: 'home/runner'
87+
REPO_SLUG: ${{ github.repository }}
88+
BRANCH: ${{ github.ref_name }}
89+
GITHUB_TOKEN: ${{ secrets.CI_USER_TOKEN }}
90+
COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }}
91+
COCOAPODS_VERSION: '1.12.1'
92+
run: |
93+
gem install cocoapods -v $COCOAPODS_VERSION
94+
Scripts/run_release.sh
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Jira ticket reference check
2+
3+
on:
4+
pull_request:
5+
types: [opened, edited, reopened, synchronize]
6+
7+
jobs:
8+
9+
jira_ticket_reference_check:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Check for Jira ticket reference
14+
uses: optimizely/github-action-ticket-reference-checker-public@master
15+
with:
16+
bodyRegex: 'FSSDK-(?<ticketNumber>\d+)'

0 commit comments

Comments
 (0)