Skip to content

Commit 927af3b

Browse files
zhu-xiaoweizhu-xiaowei
authored and
zhu-xiaowei
committed
feat: init implementation of flutter sdk
1 parent bc29173 commit 927af3b

File tree

103 files changed

+3990
-7
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+3990
-7
lines changed
+88
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
name: Bug Report
2+
description: Create a report to help us improve
3+
body:
4+
- type: textarea
5+
id: description
6+
attributes:
7+
label: Describe the bug
8+
description: A clear and concise description of what the bug is.
9+
validations:
10+
required: true
11+
- type: textarea
12+
id: repro
13+
attributes:
14+
label: Steps To Reproduce
15+
description: How do you trigger this bug? Please walk us through it step by step.
16+
value: |
17+
Steps to reproduce the behavior:
18+
1. Go to '...'
19+
2. Click on '....'
20+
3. Scroll down to '....'
21+
4. See error
22+
render: dart
23+
validations:
24+
required: true
25+
- type: textarea
26+
id: behavior
27+
attributes:
28+
label: Expected behavior
29+
description: A clear and concise description of what you expected to happen.
30+
validations:
31+
required: true
32+
- type: input
33+
id: clickstream-version
34+
attributes:
35+
label: ClickstreamAnalytic Flutter SDK Version
36+
placeholder: e.g. 1.0.0
37+
validations:
38+
required: true
39+
- type: input
40+
id: flutter-version
41+
attributes:
42+
label: Flutter version
43+
placeholder: e.g. 3.3.0
44+
validations:
45+
required: true
46+
- type: input
47+
id: platform
48+
attributes:
49+
label: The platform of the bug
50+
placeholder: |
51+
- e.g. Android/iOS/All
52+
validations:
53+
required: true
54+
- type: textarea
55+
id: logs
56+
attributes:
57+
label: Relevant log output
58+
description: >-
59+
Include any relevant log output
60+
value: |
61+
<details>
62+
<summary>Log Messages</summary>
63+
64+
```
65+
INSERT LOG MESSAGES HERE
66+
```
67+
</details>
68+
render: shell
69+
- type: dropdown
70+
id: regression
71+
attributes:
72+
label: Is this a regression?
73+
multiple: false
74+
options:
75+
- "Yes"
76+
- "No"
77+
validations:
78+
required: true
79+
- type: textarea
80+
id: regression-info
81+
attributes:
82+
label: Regression additional context
83+
placeholder: If it was a regression provide the versions used before and after the upgrade.
84+
- type: textarea
85+
id: context
86+
attributes:
87+
label: Additional context
88+
description: Add any other context about the problem here.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Feature request
2+
description: Suggest an idea for this project
3+
body:
4+
- type: textarea
5+
id: description
6+
attributes:
7+
label: Is your feature request related to a problem? Please describe.
8+
description: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
9+
validations:
10+
required: true
11+
12+
- type: textarea
13+
id: proposal
14+
attributes:
15+
label: Describe the solution you'd like
16+
description: A clear and concise description of what you want to happen.
17+
validations:
18+
required: true
19+
20+
- type: textarea
21+
id: alternatives
22+
attributes:
23+
label: Describe alternatives you've considered
24+
description: A clear and concise description of any alternative solutions or features you've considered.
25+
validations:
26+
required: true
27+
28+
- type: textarea
29+
id: context
30+
attributes:
31+
label: Additional context
32+
description: Add any other context about the problem here.

.github/PULL_REQUEST_TEMPLATE.md

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
## Issue \#
2+
<!-- If applicable, please link to issue(s) this change addresses -->
3+
4+
## Description
5+
<!-- Why is this change required? What problem does it solve? -->
6+
7+
## General Checklist
8+
<!-- Check or cross out if not relevant -->
9+
10+
- [ ] Added new tests to cover change, if needed
11+
- [ ] Security oriented best practices and standards are followed (e.g. using input sanitization, principle of least privilege, etc)
12+
- [ ] Documentation update for the change if required
13+
- [ ] PR title conforms to conventional commit style
14+
- [ ] If breaking change, documentation/changelog update with migration instructions
15+
16+
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

.github/release.yml

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
changelog:
2+
categories:
3+
- title: Feature
4+
labels:
5+
- enhancement
6+
- title: Fix
7+
labels:
8+
- bug
9+
- title: Other Changes
10+
labels:
11+
- "*"

.github/workflows/build-android.yml

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Flutter SDK Build for Android
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
build-android:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
- uses: actions/setup-java@v3
15+
with:
16+
distribution: 'corretto'
17+
java-version: '11'
18+
- uses: subosito/flutter-action@v2
19+
with:
20+
channel: 'stable'
21+
- name: Run build apk
22+
run: |
23+
flutter pub get
24+
cd example
25+
flutter build apk

.github/workflows/build-ios.yml

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Flutter SDK Build for iOS
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
build-ios:
11+
runs-on: macos-13-xl
12+
steps:
13+
- uses: actions/checkout@v3
14+
- name: Initialize submodules
15+
run: |
16+
git submodule update --init
17+
- uses: subosito/flutter-action@v2
18+
with:
19+
channel: 'stable'
20+
architecture: x64
21+
- name: Run build ios
22+
run: |
23+
flutter pub get
24+
cd example
25+
flutter build ios --release --no-codesign

.github/workflows/code-lint.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Flutter SDK Lint
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
code-lint:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
- uses: subosito/flutter-action@v2
15+
with:
16+
channel: 'stable'
17+
- run: flutter --version
18+
- name: Run install packages
19+
run: flutter pub get
20+
- name: Run code format
21+
run: dart format . --set-exit-if-changed
22+
- name: Run code lint
23+
run: flutter analyze --fatal-warnings

.github/workflows/release.yml

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Release Next Version
2+
on:
3+
workflow_dispatch:
4+
inputs:
5+
release_tag:
6+
description: 'Release Tag'
7+
required: true
8+
type: string
9+
env:
10+
NEW_VERSION: ${{ github.event.inputs.release_tag }}
11+
jobs:
12+
release:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v3
16+
with:
17+
ref: main
18+
fetch-depth: 0
19+
token: ${{ secrets.PROJECT_TOKEN }}
20+
- name: Modify for next release
21+
run: |
22+
chmod +x release.sh
23+
./release.sh ${{ env.NEW_VERSION }}
24+
git diff
25+
git config user.name '${{ vars.USER_NAME }}'
26+
git config user.email '${{ vars.USER_EMAIL }}'
27+
git add .
28+
git commit -m 'release: clickstream Flutter ${{ env.NEW_VERSION }}'
29+
git push
30+
git tag v${{ env.NEW_VERSION }}
31+
git push origin v${{ env.NEW_VERSION }}
32+
- name: Create GitHub release
33+
uses: softprops/action-gh-release@v1
34+
with:
35+
name: "Clickstream Flutter ${{ env.NEW_VERSION }}"
36+
tag_name: "v${{ env.NEW_VERSION }}"
37+
prerelease: true
38+
generate_release_notes: true

.github/workflows/test.yml

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Flutter SDK Test
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
code-test:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
- uses: subosito/flutter-action@v2
15+
with:
16+
channel: 'stable'
17+
- name: Run test
18+
run: |
19+
flutter pub get
20+
flutter test --coverage --reporter github
21+
- name: Upload Test Report
22+
uses: codecov/codecov-action@v3
23+
with:
24+
name: report
25+
files: coverage/lcov.info

.github/workflows/title-lint.yml

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Pull Request Title Lint
2+
3+
on:
4+
pull_request:
5+
branches: [ "*" ]
6+
7+
jobs:
8+
title-lint:
9+
runs-on: ubuntu-latest
10+
permissions:
11+
pull-requests: write
12+
steps:
13+
- uses: amannn/action-semantic-pull-request@v5
14+
env:
15+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
16+
with:
17+
types: |-
18+
feat
19+
fix
20+
chore
21+
docs
22+
ci
23+
tests
24+
requireScope: false

.gitignore

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Miscellaneous
2+
*.class
3+
*.log
4+
*.pyc
5+
*.swp
6+
.DS_Store
7+
.atom/
8+
.buildlog/
9+
.history
10+
.svn/
11+
migrate_working_dir/
12+
13+
# IntelliJ related
14+
*.iml
15+
*.ipr
16+
*.iws
17+
.idea/
18+
19+
# The .vscode folder contains launch configuration and tasks you configure in
20+
# VS Code which you may wish to be included in version control, so this line
21+
# is commented out by default.
22+
#.vscode/
23+
24+
# Flutter/Dart/Pub related
25+
# Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock.
26+
/pubspec.lock
27+
**/doc/api/
28+
.dart_tool/
29+
.packages
30+
build/
31+
coverage/

.gitmodules

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "ios/Clickstream"]
2+
path = ios/Clickstream
3+
url = https://github.com/awslabs/clickstream-swift

.metadata

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# This file tracks properties of this Flutter project.
2+
# Used by Flutter tool to assess capabilities and perform upgrades etc.
3+
#
4+
# This file should be version controlled and should not be manually edited.
5+
6+
version:
7+
revision: "ead455963c12b453cdb2358cad34969c76daf180"
8+
channel: "stable"
9+
10+
project_type: plugin
11+
12+
# Tracks metadata for the flutter migrate command
13+
migration:
14+
platforms:
15+
- platform: root
16+
create_revision: ead455963c12b453cdb2358cad34969c76daf180
17+
base_revision: ead455963c12b453cdb2358cad34969c76daf180
18+
- platform: android
19+
create_revision: ead455963c12b453cdb2358cad34969c76daf180
20+
base_revision: ead455963c12b453cdb2358cad34969c76daf180
21+
- platform: ios
22+
create_revision: ead455963c12b453cdb2358cad34969c76daf180
23+
base_revision: ead455963c12b453cdb2358cad34969c76daf180
24+
25+
# User provided section
26+
27+
# List of Local paths (relative to this file) that should be
28+
# ignored by the migrate tool.
29+
#
30+
# Files that are not part of the templates will be ignored by default.
31+
unmanaged_files:
32+
- 'lib/main.dart'
33+
- 'ios/Runner.xcodeproj/project.pbxproj'

0 commit comments

Comments
 (0)