-
-
Notifications
You must be signed in to change notification settings - Fork 2
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 #6 from ziqq/feat/github-5/namespace-in-build.gradle
- Loading branch information
Showing
135 changed files
with
4,602 additions
and
801 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 |
---|---|---|
@@ -1 +1 @@ | ||
3.22.3 | ||
3.24.1 |
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 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 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 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,53 @@ | ||
name: Deploy to Pub.dev | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
tags: | ||
- "[0-9]+.[0-9]+.[0-9]+*" | ||
|
||
jobs: | ||
deploy: | ||
name: "Deploy to Pub.dev" | ||
permissions: | ||
id-token: write # Required for authentication using OIDC | ||
runs-on: ubuntu-latest | ||
container: | ||
image: plugfox/flutter:stable | ||
options: --user root | ||
steps: | ||
# Checkout repository | ||
- name: 🚂 Get latest code | ||
uses: actions/checkout@v4 | ||
|
||
- name: 🗄️ Export pub cache directory | ||
run: | | ||
git config --global --add safe.directory /opt/flutter | ||
export PUB_CACHE=$PWD/.pub_cache/ | ||
- name: 🚃 Cache pub modules | ||
id: cache-pub-modules | ||
uses: actions/cache@v3 | ||
env: | ||
cache-name: cache-pub-modules | ||
with: | ||
key: ${{ runner.os }}-pub-${{ env.cache-name }} | ||
path: | | ||
$PWD/.pub_cache/ | ||
$PWD/.dart_tool/ | ||
$PWD/.flutter-plugins | ||
$PWD/.flutter-plugins-dependencies | ||
$PWD/.packages | ||
- name: 👷 Get dependencies | ||
run: | | ||
flutter pub get | ||
timeout-minutes: 5 | ||
|
||
- name: 🏗️ Publish - dry run | ||
run: flutter pub publish --dry-run | ||
timeout-minutes: 5 | ||
|
||
- name: 🔥 Publish to pub.dev | ||
run: yes | flutter pub publish -f --skip-validation | ||
timeout-minutes: 5 |
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 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 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 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 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 |
---|---|---|
@@ -1,15 +1,72 @@ | ||
include tool/makefile/main.mk | ||
include tool/makefile/pub.mk | ||
include tool/makefile/setup.mk | ||
include tool/makefile/test.mk | ||
|
||
# This help dialog | ||
# https://gist.github.com/prwhite/8168133#gistcomment-1313022 | ||
.PHONY: help | ||
help: | ||
@echo "Let's make something good" | ||
@make -s version | ||
@echo "Available commands:" | ||
@awk '/^#/ {comment = substr($$0, 3); next} /^[a-zA-Z_0-9-]+:/ {print $$1 " " comment; comment=""}' $(MAKEFILE_LIST) | ||
help: ## Help dialog | ||
@echo 'Usage: make <OPTIONS> ... <TARGETS>' | ||
@echo '' | ||
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' | ||
|
||
.PHONY: doctor | ||
doctor: ## Check fvm flutter doctor | ||
@fvm flutter doctor | ||
|
||
.PHONY: version | ||
version: ## Check fvm flutter version | ||
@fvm flutter --version | ||
|
||
|
||
.PHONY: format | ||
format: ## Format code | ||
@echo "╠ RUN FORMAT THE CODE" | ||
@fvm dart format --fix -l 80 . || (echo "👀 Format code error 👀"; exit 1) | ||
@echo "╠ CODE FORMATED SUCCESSFULLY" | ||
|
||
.PHONY: fix | ||
fix: format ## Fix code | ||
@fvm dart fix --apply lib | ||
|
||
.PHONY: clean-cache | ||
clean-cache: ## Clean the pub cache | ||
@echo "╠ CLEAN PUB CACHE" | ||
@fvm flutter pub cache repair | ||
@echo "╠ PUB CACHE CLEANED SUCCESSFULLY" | ||
|
||
.PHONY: get | ||
get: ## Get dependencies | ||
@echo "╠ RUN GET DEPENDENCIES..." | ||
@flutter pub get || (echo "▓▓ Get dependencies error ▓▓"; exit 1) | ||
@echo "╠ DEPENDENCIES GETED SUCCESSFULLY" | ||
|
||
.PHONY: analyze | ||
analyze: get format ## Analyze code | ||
@echo "╠ RUN ANALYZE THE CODE..." | ||
@dart analyze --fatal-infos --fatal-warnings | ||
@echo "╠ ANALYZED CODE SUCCESSFULLY" | ||
|
||
.PHONY: check | ||
check: analyze ## Check code | ||
@echo "╠ RUN CECK CODE..." | ||
@dart pub publish --dry-run | ||
@dart pub global activate pana | ||
@pana --json --no-warning --line-length 80 > log.pana.json | ||
@echo "╠ CECKED CODE SUCCESSFULLY" | ||
|
||
.PHONY: publish | ||
publish: ## Publish package | ||
@echo "╠ RUN PUBLISHING..." | ||
@dart pub publish --server=https://pub.dartlang.org || (echo "▓▓ Publish error ▓▓"; exit 1) | ||
@echo "╠ PUBLISH PACKAGE SUCCESSFULLY" | ||
|
||
.PHONY: coverage | ||
coverage: ## Runs get coverage | ||
@lcov --summary coverage/lcov.info | ||
|
||
.PHONY: genhtml | ||
genhtml: ## Runs generage coverage html | ||
@genhtml coverage/lcov.info -o coverage/html | ||
|
||
.PHONY: test-unit | ||
test-unit: ## Runs unit tests | ||
@echo "╠ RUNNING UNIT TESTS..." | ||
@flutter test --coverage || (echo "Error while running tests"; exit 1) | ||
@genhtml coverage/lcov.info --output=coverage -o coverage/html || (echo "Error while running tests"; exit 2) | ||
@echo "╠ UNIT TESTS SUCCESSFULLY" | ||
|
Oops, something went wrong.