-
Notifications
You must be signed in to change notification settings - Fork 141
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
1 parent
8eadcdc
commit 5b10e9c
Showing
4 changed files
with
89 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,40 @@ | ||
os: linux | ||
dist: trusty | ||
jdk: oraclejdk8 | ||
language: ruby | ||
addons: | ||
apt: | ||
# Flutter depends on /usr/lib/x86_64-linux-gnu/libstdc++.so.6 version GLIBCXX_3.4.18 | ||
sources: | ||
- ubuntu-toolchain-r-test # if we don't specify this, the libstdc++6 we get is the wrong version | ||
packages: | ||
- lib32stdc++6 # https://github.com/flutter/flutter/issues/6207 | ||
- libstdc++6 | ||
- curl | ||
cache: | ||
directories: | ||
- $HOME/.pub-cache | ||
before_script: | ||
- git clone https://github.com/flutter/flutter.git -b stable --depth 1 | ||
- export PATH=`pwd`/flutter/bin:`pwd`/flutter/bin/cache/dart-sdk/bin:$PATH | ||
install: | ||
- gem install coveralls-lcov | ||
script: | ||
- flutter doctor -v | ||
- make | ||
after_success: | ||
- coveralls-lcov --repo-token $COVERALLS_TOKEN coverage/lcov.info | ||
|
||
deploy: | ||
# validating branch master for deploying | ||
- provider: script | ||
skip_cleanup: true | ||
script: bash scripts/deploy.sh && rm -rf scripts/ && pub publish -n -v | ||
on: | ||
branch: master | ||
# deploy tagged to pub server | ||
- provider: script | ||
skip_cleanup: true | ||
script: bash scripts/deploy.sh && rm -rf scripts/ && pub publish -f -v | ||
on: | ||
tags: true |
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,28 @@ | ||
DARTANALYZER_FLAGS=--fatal-warnings | ||
|
||
build: lib/*dart test/*dart deps | ||
dartanalyzer ${DARTANALYZER_FLAGS} lib/ | ||
dartfmt -n --set-exit-if-changed lib/ test/ | ||
flutter test --coverage --coverage-path ./coverage/lcov.info | ||
|
||
deps: pubspec.yaml | ||
flutter packages get -v | ||
|
||
reformatting: | ||
dartfmt -w lib/ test/ | ||
|
||
build-local: reformatting build | ||
genhtml -o coverage coverage/lcov.info | ||
lcov --list coverage/lcov.info | ||
lcov --summary coverage/lcov.info | ||
open coverage/index.html | ||
|
||
pana: | ||
pana -s path . | ||
|
||
docs: | ||
rm -rf doc | ||
dartdoc --exclude 'dart:async,dart:collection,dart:convert,dart:core,dart:developer,dart:io,dart:isolate,dart:math,dart:typed_data,dart:ui,dart:html_common,dart:ffi,dart:html,dart:js,dart:js_util' | ||
|
||
publish: | ||
pub publish |
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,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
if [[ ! -e ~/.pub-cache/credentials.json ]]; then | ||
mkdir -p ~/.pub-cache | ||
touch ~/.pub-cache/credentials.json | ||
fi | ||
|
||
cat <<EOF > ~/.pub-cache/credentials.json | ||
{ | ||
"accessToken":"$PUB_ACCESS_TOKEN", | ||
"refreshToken":"$PUB_REFRESH_TOKEN", | ||
"tokenEndpoint":"$PUB_TOKEN_ENDPOINT", | ||
"scopes":[$PUB_SCOPES], | ||
"expiration":$PUB_EXPIRATION | ||
} | ||
EOF |
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,5 @@ | ||
#!/usr/bin/env bash | ||
|
||
bash /scripts/credentials.sh | ||
make deps | ||
make docs |