-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 0d170d3
Showing
557 changed files
with
52,999 additions
and
0 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,3 @@ | ||
BasedOnStyle: Google | ||
IndentWidth: 2 | ||
AlwaysBreakTemplateDeclarations: Yes |
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,11 @@ | ||
# editorconfig | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
quote_type = single |
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,43 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
# Report a bug | ||
Thank you for using Patapata. This is an issue to report any problems or bugs related to Patapata's features. Please provide the steps to reproduce the issue, the results of those steps, logs, Flutter doctor output, and any sample code if available. | ||
|
||
## Description | ||
- <!--- Please provide details of the issue at hand. ---> | ||
|
||
### Reproduction Steps | ||
- <!--- Please provide the steps to reproduce the issue or share any sample code or projects if available. ---> | ||
|
||
### Reproduction Steps Result | ||
- <!--- Please describe the results of the reproduction steps. ---> | ||
|
||
### Environment | ||
- | ||
<!--- | ||
Please provide information about the environment where the issue occurs. For problems occurring on physical devices, specify the Android or iOS version. For issues within development environments, mention the versions of VSCode, Android Studio, or XCode you are using. | ||
- For example, please fill in items like the following: | ||
- Platform | ||
- Android | ||
- iOS | ||
- Windows | ||
- MacOS | ||
- Linux | ||
---> | ||
|
||
### Logs | ||
- | ||
<!--- | ||
Please include logs when the issue or bug occurs. If possible, provide detailed logs using `flutter run --verbose`. However, do not paste the log results as screenshots. | ||
---> | ||
|
||
### **Flutter Doctor Result** | ||
- | ||
<!--- Please include the results of running `flutter doctor` ---> |
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,24 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
# Feature Request | ||
Thank you for using Patapata. This is an issue for requesting new features for Patapata. Please provide the details of the feature you would like to add to Patapata. | ||
|
||
## Description | ||
- | ||
<!--- | ||
- Please describe in detail the content of the feature you would like to add to Patapata. | ||
- If you have images, videos, or sample code that can help visualize the added feature, please include them. | ||
- Explain why this feature is necessary for Patapata. | ||
---> | ||
|
||
## Similar Features | ||
- | ||
<!--- | ||
- If you have used alternatives or similar features on platforms like pub.dev, please mention them. ---> |
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,15 @@ | ||
--- | ||
name: Other issue | ||
about: Create regarding other issues | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
# Other Issue | ||
Thank you for using Patapata. This is an issue for reporting bugs, problems, or making suggestions other than adding new features. | ||
|
||
## Description | ||
- | ||
<!--- Please provide details of the issue or suggestion. ---> |
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,17 @@ | ||
<!--- | ||
Before submitting a PR, please check the following: | ||
- [ ] Have you created an issue? | ||
- [ ] Have you verified that the code changes for this PR pass Patapata's test suite? | ||
- [ ] Have you reviewed Patapata's licensing? | ||
---> | ||
|
||
# Issue Number | ||
#{IssueNumber} | ||
<!--- | ||
- Please specify the Patapata issue number. | ||
- Add the number after the hashtag (#). (For example, please write it as #1) | ||
---> | ||
|
||
# Summary | ||
- | ||
<!--- Please describe what was done or fixed in this PR. ---> |
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,58 @@ | ||
# This workflow uses actions that are not certified by GitHub. | ||
# They are provided by a third-party and are governed by | ||
# separate terms of service, privacy policy, and support | ||
# documentation. | ||
|
||
name: Check | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
check: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
flutterVersion: | ||
- '3.19.3' | ||
- '3.16.9' | ||
- '3.13.9' | ||
- '3.13.0' | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: subosito/flutter-action@v2 | ||
with: | ||
flutter-version: ${{ matrix.flutterVersion }} | ||
channel: 'stable' | ||
cache: true | ||
|
||
- name: Setup Go environment | ||
uses: actions/setup-go@v4.1.0 | ||
|
||
- name: Install dependencies | ||
run: |- | ||
go install github.com/google/addlicense@latest | ||
flutter pub get | ||
dart pub global activate melos | ||
melos bootstrap | ||
- name: Analyze project source | ||
run: melos run lint:all | ||
|
||
- name: Run tests | ||
run: melos run test:all | ||
|
||
- name: Check license headers | ||
run: melos run check-license-header | ||
|
||
- name: Test building Android | ||
run: melos run build:example_android | ||
|
||
- name: Test building web | ||
run: melos run build:example_web |
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: Upload Codecov | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Set up Flutter | ||
uses: subosito/flutter-action@v2 | ||
with: | ||
channel: 'stable' | ||
|
||
- name: Install dependencies | ||
run: flutter pub get | ||
working-directory: ./packages/patapata_core | ||
|
||
- name: Run tests for coverage | ||
run: flutter test --dart-define=IS_TEST=true --no-pub --coverage | ||
working-directory: ./packages/patapata_core | ||
|
||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} |
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,14 @@ | ||
.vscode/* | ||
.DS_Store | ||
**/coverage | ||
pubspec_overrides.yaml | ||
.dart_tool | ||
.melos_tool | ||
.atom | ||
.idea | ||
.packages | ||
.pub | ||
.symlinks | ||
pubspec.lock | ||
|
||
! .vscode/launch.json |
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,6 @@ | ||
--indent 2 | ||
--maxwidth 100 | ||
--wrapparameters afterfirst | ||
--disable sortedImports,unusedArguments,wrapMultilineStatementBraces | ||
--exclude Pods,**/MainFlutterWindow.swift,**/AppDelegate.swift,**/.symlinks/** | ||
--swiftversion 5.7 |
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 @@ | ||
# Change Log | ||
|
||
All notable changes to this project will be documented in this file. | ||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. |
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,141 @@ | ||
# Contribution to Patapata | ||
|
||
This is a guideline on how to contribute to Patapata. By following these guidelines, anyone can contribute to Patapata. | ||
|
||
## Issues | ||
|
||
If you have any issues related to Patapata, please report them. When you do, use a template from GitHub Issues. | ||
|
||
- Report errors here in this Issue. | ||
- Share your opinions on questions or feature requests related to Patapata here in this Issue. | ||
- For any other questions, please use this Issue. | ||
|
||
## Pull Request | ||
|
||
If you have any modifications related to Patapata, please submit a PR (Pull Request). In this case, please adhere to the following guidelines: | ||
|
||
- Submit the PR against the next branch. | ||
- Fill in the necessary items in the template when creating the PR. | ||
- Assign it an issue number and appropriate labels. | ||
- Ensure it meets the test and coverage requirements with `melos run test:all` or manually with `flutter test --dart-define=IS_TEST=true` for all plugins and core. | ||
- Generally, if you're adding additional Dart files, include their corresponding test code as well. | ||
|
||
## Copyright Notice | ||
|
||
Patapata uses the MIT License. The rights to this open-source software are owned by GREE, Inc., and the company retains these rights even after the software is publicly released. | ||
|
||
Regarding modifications made by individuals other than GREE, Inc., the rights to the modified portions belong to the person who made the modifications. | ||
|
||
When creating source code in languages like Dart, Kotlin, Swift, etc., it is essential to include the MIT License at the beginning of the file. Please follow the formatting guidelines specific to the programming language. Below, I'll provide an example of the license statements that are typically included in Dart, Kotlin, and Swift files managed in Patapata: | ||
|
||
dart | ||
|
||
```dart | ||
// Copyright (c) GREE, Inc. | ||
// | ||
// This source code is licensed under the MIT license found in the | ||
// LICENSE file in the root directory of this source tree. | ||
``` | ||
|
||
Kotlin | ||
|
||
```kotlin | ||
/* | ||
* Copyright (c) GREE, Inc. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
``` | ||
|
||
Swift | ||
|
||
```swift | ||
// Copyright (c) GREE, Inc. | ||
// | ||
// This source code is licensed under the MIT license found in the | ||
// LICENSE file in the root directory of this source tree. | ||
``` | ||
|
||
You can also use the melos command to automatically add the license statement to the file. | ||
|
||
`melos run add-license-header` | ||
|
||
Note that you will need a working go environment with [addlicense](https://github.com/google/addlicense) installed to use this command. | ||
|
||
## Coding Conventions | ||
|
||
- We generally follow the [effective-dart](https://dart.dev/guides/language/effective-dart/style) guidelines. | ||
- We adhere to the [Flutter formatting rules](https://flutter.dev/docs/development/tools/formatting). | ||
- We follow the rules of the [Linter](https://dart-lang.github.io/linter/lints/index.html). | ||
|
||
### Other Coding Conventions | ||
|
||
- Start all local variables with 't,' where 't' stands for temporary. We do this to instantly understand if a variable will affect something outside of the current scope without having to manually looking at the declaration. | ||
|
||
```dart | ||
void main() async { | ||
final App tApp = createApp(); | ||
... | ||
tApp.run(); | ||
} | ||
``` | ||
|
||
- Iterator-related variables in constructs like `for` loops can remain as 'i' or similar; there's no issue with that. | ||
|
||
```dart | ||
for (var i = 0; i < 10; i++) { | ||
print("count : $i"); | ||
} | ||
``` | ||
|
||
- For internal function names, begin with 'f.' We do this to instantly understand when a function is a local function versus anything else. For example: | ||
|
||
```dart | ||
void exampleFunc() { | ||
fHogeHoge() { | ||
... | ||
} | ||
fHogeHoge(); | ||
} | ||
``` | ||
|
||
- Start private static variables with '_s.’ This is to instantly understand that these variables are static and will possibly affect multiple areas of the codebase as well as not being tied to the current instance. | ||
|
||
```dart | ||
static var _sCounter = 0; | ||
``` | ||
|
||
- For constants, begin private ones with '_k' and public ones with 'k.’ | ||
|
||
```dart | ||
const _kMyNum = 1; | ||
const kMyPublicNum = 1; | ||
``` | ||
|
||
- After an 'if (...)' statement, always include curly braces '{}' and a newline. Avoid writing it on a single line without curly braces. For if expressions this is not required. | ||
|
||
```dart | ||
// OK | ||
if (something) { | ||
doThat(); | ||
} | ||
// NG | ||
if (something) doThat(); | ||
// OK | ||
final tArray = [ | ||
if (something) 2, | ||
]; | ||
``` | ||
|
||
## Project Management | ||
|
||
Patapata uses [melos](https://melos.invertase.dev/) to manage this monorepository. Please refer to the melos documentation for more information. | ||
|
||
## Quality Assurance | ||
|
||
- Patapata aims to support the latest Flutter version as much as possible. However, there may be times when it cannot be compatible with that version due to Flutter's update changes. | ||
- Patapata strives to achieve as close to 100% test code coverage as possible. |
Oops, something went wrong.