-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Various maintainance fixes * Add build * Update build
- Loading branch information
Showing
27 changed files
with
418 additions
and
939 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,26 @@ | ||
name: Android CI | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: set up JDK 11 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '11' | ||
distribution: 'temurin' | ||
cache: gradle | ||
|
||
- name: Grant execute permission for gradlew | ||
run: chmod +x gradlew | ||
- name: Build with Gradle | ||
run: ./gradlew build |
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,10 +1,158 @@ | ||
allprojects { | ||
repositories { | ||
buildscript { | ||
ext.repos = { | ||
mavenLocal() | ||
mavenCentral() | ||
google() | ||
jcenter() | ||
} | ||
|
||
repositories repos | ||
} | ||
|
||
plugins { | ||
id 'org.owasp.dependencycheck' version '6.5.3' apply false | ||
id 'com.github.ben-manes.versions' version '0.42.0' apply false | ||
id('io.github.gradle-nexus.publish-plugin') version '1.1.0' | ||
} | ||
|
||
ext { | ||
junitJupiterVersion = '5.10.2' | ||
} | ||
|
||
task clean(type: Delete) { | ||
delete rootProject.buildDir | ||
} | ||
|
||
def javaLibraryProjects() { | ||
subprojects.findAll { new File(it.projectDir, 'build.gradle').file } | ||
} | ||
|
||
allprojects { | ||
// skip checking test configurations (like lint) or test libraries for vulnerabilities | ||
apply plugin: 'org.owasp.dependencycheck' | ||
|
||
buildscript { | ||
repositories repos | ||
} | ||
repositories repos | ||
|
||
configurations.all { | ||
// Check for updates every build | ||
// A module with a *-SNAPSHOT version coming from a Maven repository will be considered changing by default. | ||
resolutionStrategy.cacheChangingModulesFor 0, 'seconds' | ||
resolutionStrategy.cacheDynamicVersionsFor 0, 'seconds' | ||
} | ||
|
||
dependencyCheck { | ||
failOnError = false // let's ignore errors to make builds more stable | ||
analyzedTypes = ['jar'] // the default artifact types that will be analyzed. | ||
// OWASP Dependency Check plugin for Jenkins needs an XML report, but humans may also need an HTML one | ||
format = 'ALL' | ||
// Specifies if the build should be failed if a CVSS score equal to or above a specified level is identified. | ||
failBuildOnCVSS = 7 | ||
// specify a list of known issues which contain false-positives | ||
suppressionFiles = ["$rootDir/dependencycheck-root-suppression.xml"] | ||
} | ||
} | ||
|
||
|
||
configure(javaLibraryProjects()) { | ||
apply plugin: 'java-library' | ||
|
||
apply plugin: 'com.github.ben-manes.versions' | ||
} | ||
|
||
|
||
configure(javaLibraryProjects()) { | ||
|
||
apply plugin: 'maven-publish' | ||
apply plugin: 'signing' | ||
|
||
repositories repos | ||
|
||
java { | ||
// Sets Java compatibility to Java 8 | ||
sourceCompatibility JavaVersion.VERSION_1_8 | ||
targetCompatibility JavaVersion.VERSION_1_8 | ||
|
||
withJavadocJar() | ||
withSourcesJar() | ||
} | ||
|
||
publishing { | ||
publications { | ||
// Creates a Maven publication called "release". | ||
release(MavenPublication) { | ||
// Applies the component for the release build variant. | ||
from components.java | ||
|
||
groupId 'com.github.skjolber.ndef-tools-for-android' | ||
artifactId "$project.ext.artifactId" | ||
version "$version" | ||
|
||
pom { | ||
name = "$project.ext.artifactName" | ||
description = "$project.ext.artifactDescription" | ||
url = 'https://github.com/skjolber/ndef-tools-for-android' | ||
organization { | ||
name = 'Thomas Rorvik Skjolberg' | ||
url = 'https://github.com/skjolber' | ||
} | ||
issueManagement { | ||
system = 'GitHub' | ||
url = 'https://github.com/skjolber/ndef-tools-for-android/issues' | ||
} | ||
licenses { | ||
license { | ||
name = 'The Apache Software License, Version 2.0' | ||
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt' | ||
distribution = 'repo' | ||
} | ||
} | ||
scm { | ||
url = 'https://github.com/skjolber/ndef-tools-for-android' | ||
connection = 'scm:[email protected]:skjolber/ndef-tools-for-android.git' | ||
developerConnection = 'scm:[email protected]:skjolber/ndef-tools-for-android.git' | ||
} | ||
developers { | ||
developer { | ||
id = 'skjolber' | ||
name = 'Thomas Rørvik Skjølberg' | ||
} | ||
} | ||
} | ||
} | ||
} | ||
if(project.hasProperty("signing.gnupg.keyName")) { | ||
signing { | ||
useGpgCmd() | ||
|
||
// set | ||
// signing.gnupg.keyName=xxx | ||
// signing.gnupg.passphrase=yyy | ||
// via command line or global gradle properties | ||
// then run | ||
// w17 build publishToSonatype --info --stacktrace | ||
|
||
sign(publishing.publications) | ||
} | ||
} | ||
|
||
} | ||
|
||
test { | ||
useJUnitPlatform { | ||
includeEngines 'junit-jupiter', 'junit-vintage' | ||
} | ||
} | ||
|
||
dependencies { | ||
// JUnit Jupiter API and TestEngine implementation | ||
testImplementation("org.junit.jupiter:junit-jupiter:${junitJupiterVersion}") | ||
} | ||
} | ||
|
||
nexusPublishing { | ||
repositories { | ||
sonatype() | ||
} | ||
} |
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,21 +1,4 @@ | ||
org.gradle.jvmargs=-Xmx1024m | ||
|
||
VERSION_NAME=2.0.1-SNAPSHOT | ||
version=2.0.1-SNAPSHOT | ||
GROUP=com.github.skjolber.ndef-tools-for-android | ||
|
||
POM_PACKAGING=jar | ||
|
||
POM_DESCRIPTION=Library for NDEF use in Android | ||
POM_URL=https://github.com/skjolber/ndef-tools-for-android | ||
POM_SCM_URL=https://github.com/skjolber/ndef-tools-for-android | ||
POM_SCM_CONNECTION=scm:[email protected]:skjolber/ndef-tools-for-android.git | ||
POM_SCM_DEV_CONNECTION=scm:[email protected]:skjolber/ndef-tools-for-android.git | ||
POM_LICENCE_NAME=The Apache Software License, Version 2.0 | ||
POM_LICENCE_URL=http://www.apache.org/licenses/LICENSE-2.0.txt | ||
POM_LICENCE_DIST=repo | ||
POM_DEVELOPER_ID=skjolber | ||
POM_DEVELOPER_NAME=Thomas Skjolberg | ||
|
||
POM_ISSUE_SYSTEM=https://github.com/skjolber/ndef-tools-for-android/issues | ||
POM_ORGANIZATION_NANE=Thomas Rorvik Skjolberg | ||
POM_ORGANIZATION_URL=https://github.com/skjolber |
This file was deleted.
Oops, something went wrong.
Binary file not shown.
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,5 +1,5 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5.1-bin.zip | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.