mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-07-13 17:51:57 +00:00
try uploading sarif file to GH
This commit is contained in:
parent
35a15299b2
commit
a0ef7e03e7
3 changed files with 7 additions and 70 deletions
5
.github/workflows/android.yml
vendored
5
.github/workflows/android.yml
vendored
|
|
@ -98,3 +98,8 @@ jobs:
|
||||||
run: chmod +x gradlew
|
run: chmod +x gradlew
|
||||||
- name: Run detekt
|
- name: Run detekt
|
||||||
run: ./gradlew detekt
|
run: ./gradlew detekt
|
||||||
|
- name: Upload SARIF to Github using the upload-sarif action
|
||||||
|
uses: github/codeql-action/upload-sarif@v1
|
||||||
|
if: $
|
||||||
|
with:
|
||||||
|
sarif_file: build/report/detekt.sarif
|
||||||
|
|
|
||||||
68
.travis.yml
68
.travis.yml
|
|
@ -1,68 +0,0 @@
|
||||||
language: android
|
|
||||||
dist: trusty
|
|
||||||
jdk: oraclejdk8
|
|
||||||
sudo: required
|
|
||||||
services:
|
|
||||||
- mongodb
|
|
||||||
addons:
|
|
||||||
apt:
|
|
||||||
sources:
|
|
||||||
- ubuntu-toolchain-r-test
|
|
||||||
packages:
|
|
||||||
- g++-4.8
|
|
||||||
before_install:
|
|
||||||
- $CXX --version
|
|
||||||
- export JAVA7_HOME=/usr/lib/jvm/java-7-oracle
|
|
||||||
- export JAVA8_HOME=/usr/lib/jvm/java-8-oracle
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then nvm install 6.9.3; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then nvm use 6.9.3; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then npm i -g npm@6; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then sudo apt-get update || true; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then sudo apt-get -y install mongodb; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then git clone https://github.com/HabitRPG/habitica.git; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then until nc -z localhost 27017; do echo Waiting for MongoDB; sleep 2; done; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then cd habitica && cp config.json.example config.json && npm install; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then npm start; fi &
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then until nc -z localhost 3000; do echo Waiting for Habitica Server; sleep 2; done; fi
|
|
||||||
- if [ $REQUIRES_SERVER = "true" ]; then cd -; fi
|
|
||||||
android:
|
|
||||||
components:
|
|
||||||
# Uncomment the lines below if you want to
|
|
||||||
# use the latest revision of Android SDK Tools
|
|
||||||
# - platform-tools
|
|
||||||
- tools
|
|
||||||
|
|
||||||
# The BuildTools version used by your project
|
|
||||||
- build-tools-28.0.3
|
|
||||||
|
|
||||||
# The SDK version used to compile your project
|
|
||||||
- android-29
|
|
||||||
|
|
||||||
# Additional components
|
|
||||||
- extra-google-google_play_services
|
|
||||||
- extra-google-m2repository
|
|
||||||
- extra-android-m2repository
|
|
||||||
|
|
||||||
# Specify at least one system image,
|
|
||||||
# if you need to run emulator(s) during your tests
|
|
||||||
#- sys-img-armeabi-v7a-android-19
|
|
||||||
#- sys-img-x86-android-17
|
|
||||||
licenses:
|
|
||||||
- 'android-sdk-preview-license-52d11cd2'
|
|
||||||
- 'android-sdk-license-.+'
|
|
||||||
- 'google-gdk-license-.+'
|
|
||||||
before_script:
|
|
||||||
- cp habitica.properties.travis habitica.properties
|
|
||||||
- cp habitica.resources.example habitica.resources
|
|
||||||
- cp Habitica/google-services.json.example Habitica/google-services.json
|
|
||||||
script:
|
|
||||||
- ./gradlew $TEST2
|
|
||||||
env:
|
|
||||||
global:
|
|
||||||
- CXX=g++-4.8
|
|
||||||
- DISABLE_REQUEST_LOGGING=true
|
|
||||||
matrix:
|
|
||||||
- TEST1="assembleDebug -PdisablePreDex"
|
|
||||||
- TEST2="testProdDebugUnitTest -PdisablePreDex --stacktrace" REQUIRES_SERVER=false
|
|
||||||
|
|
@ -43,9 +43,9 @@ detekt {
|
||||||
enabled = true // Enable/Disable HTML report (default: true)
|
enabled = true // Enable/Disable HTML report (default: true)
|
||||||
destination = file("build/reports/detekt.html") // Path where HTML report will be stored (default: `build/reports/detekt/detekt.html`)
|
destination = file("build/reports/detekt.html") // Path where HTML report will be stored (default: `build/reports/detekt/detekt.html`)
|
||||||
}
|
}
|
||||||
txt {
|
sarif {
|
||||||
enabled = true // Enable/Disable TXT report (default: true)
|
enabled = true // Enable/Disable TXT report (default: true)
|
||||||
destination = file("build/reports/detekt.txt") // Path where TXT report will be stored (default: `build/reports/detekt/detekt.txt`)
|
destination = file("build/reports/detekt.sarif") // Path where TXT report will be stored (default: `build/reports/detekt/detekt.txt`)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
Reference in a new issue