Skip to content

Commit

Permalink
Overhaul build
Browse files Browse the repository at this point in the history
Just enough to get GitHub Actions working and somewhat modernizing the rest. Didn't do too much because this project is not actively developed.
  • Loading branch information
JakeWharton committed Nov 9, 2022
1 parent 205ea5a commit f24df17
Show file tree
Hide file tree
Showing 13 changed files with 203 additions and 423 deletions.
7 changes: 7 additions & 0 deletions .github/dependabot.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: 2

updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
30 changes: 30 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: build

on:
pull_request: {}
push:
branches:
- '**'
tags-ignore:
- '**'

jobs:
build:
runs-on: macos-latest

steps:
- uses: actions/checkout@v3
- uses: gradle/[email protected]

- uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 8

- run: ./gradlew build

- run: ./gradlew publish
if: ${{ github.ref == 'refs/heads/3.x' && github.repository == 'ReactiveX/RxAndroid' }}
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPE_USER }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.SONATYPE_PASSWORD }}
10 changes: 0 additions & 10 deletions .github/workflows/gradle-wrapper-validation.yml

This file was deleted.

26 changes: 26 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: release

on:
push:
tags:
- '**'

jobs:
release:
runs-on: macos-latest

steps:
- uses: actions/checkout@v3
- uses: gradle/[email protected]

- uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 8

- run: ./gradlew publish
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPE_USER }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.SONATYPE_PASSWORD }}
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.SIGNING_PRIVATE_KEY }}
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.SIGNING_PASSWORD }}
68 changes: 4 additions & 64 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,70 +1,10 @@
# Compiled source #
###################
*.class

# Packages #
############
# it's better to unpack these files and commit the raw source
# git has its own built in compression methods
*.7z
*.dmg
*.gz
*.iso
*.rar
*.tar
*.zip

# Logs and databases #
######################
*.log

# OS generated files #
######################
.DS_Store*
ehthumbs.db
Icon?
Thumbs.db

# Editor Files #
################
*~
*.swp

# Gradle Files #
################
# Gradle
.gradle
.gradletasknamecache
.m2

# Build output directies
target/
build/
build
reports

# IntelliJ specific files/directories
out
# IntelliJ
.idea
*.ipr
*.iws
*.iml
atlassian-ide-plugin.xml

# AndroidStudio specific files/directories
local.properties

# Eclipse specific files/directories
.classpath
.project
.settings
.metadata
bin/

# NetBeans specific files/directories
.nbattrs
/.nb-gradle/profiles/private/
.nb-gradle-properties

# Android
local.properties

# jEnv
.java-version
39 changes: 0 additions & 39 deletions .travis.yml

This file was deleted.

15 changes: 10 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,26 @@ buildscript {
repositories {
google()
mavenCentral()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.2.2'
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.5'
classpath 'org.jfrog.buildinfo:build-info-extractor-gradle:4.7.5'
classpath 'com.vanniktech:gradle-maven-publish-plugin:0.18.0'
}
}

allprojects {
repositories {
google()
mavenCentral()
jcenter()
}

tasks.withType(Test).configureEach {
testLogging {
if (System.getenv("CI") == "true") {
events = ["failed", "skipped", "passed"]
}
exceptionFormat "full"
}
}
}

Expand Down
20 changes: 15 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
android.enableJetifier=false
android.useAndroidX=true
org.gradle.jvmargs=-Xmx2048m

android.useAndroidX=true
android.enableJetifier=false
android.defaults.buildfeatures.buildconfig=false
android.defaults.buildfeatures.aidl=false
android.defaults.buildfeatures.renderscript=false
android.defaults.buildfeatures.resvalues=false
android.defaults.buildfeatures.shaders=false

GROUP=io.reactivex.rxjava3
VERSION_NAME=3.0.1
VERSION_NAME=3.0.1-SNAPSHOT

POM_NAME=RxAndroid
POM_PACKAGING=aar
POM_DESCRIPTION=RxAndroid

POM_URL=https://github.com/ReactiveX/RxAndroid
Expand All @@ -14,5 +20,9 @@ POM_SCM_CONNECTION=scm:git:https://github.com/ReactiveX/RxAndroid.git
POM_SCM_DEV_CONNECTION=scm:git:[email protected]:ReactiveX/RxAndroid.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_URL=https://www.apache.org/licenses/LICENSE-2.0.txt
POM_LICENCE_DIST=repo

POM_DEVELOPER_ID=reactivex
POM_DEVELOPER_NAME=ReactiveX
POM_DEVELOPER_URL=https://github.com/ReactiveX
68 changes: 0 additions & 68 deletions gradle/artifacts.gradle

This file was deleted.

16 changes: 0 additions & 16 deletions gradle/buildViaTravis.sh

This file was deleted.

Loading

0 comments on commit f24df17

Please sign in to comment.