Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These are supported funding model platforms

github: awxkee
39 changes: 39 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Build to Maven Local

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

on:
push:
branches:
- 'master'
tags-ignore:
- '*'
pull_request:
branches:
- 'master'

jobs:
build:
runs-on: ubuntu-latest
environment: Maven Central
steps:
- uses: actions/checkout@v3
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
cache: gradle
- name: Set version variable
run: echo "GITHUB_REF_NAME=$GITHUB_REF_NAME" >> $GITHUB_ENV
- name: Compile to maven local
env:
VERSION_NAME: ${{ env.GITHUB_REF_NAME }}
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.ORG_GRADLE_PROJECT_MAVENCENTRALUSERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.ORG_GRADLE_PROJECT_MAVENCENTRALPASSWORD }}
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEY }}
ORG_GRADLE_PROJECT_signingInMemoryKeyId: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEYID }}
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEYPASSWORD }}
run: bash ./gradlew avifglide:publishToMavenLocal
35 changes: 35 additions & 0 deletions .github/workflows/create_release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Create Release

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

on:
push:
tags:
- '*'

jobs:
build:
runs-on: ubuntu-latest
environment: Maven Central
steps:
- uses: actions/checkout@v3
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
cache: gradle
- name: Set version variable
run: echo "GITHUB_REF_NAME=$GITHUB_REF_NAME" >> $GITHUB_ENV
- name: Compile to Maven Central
env:
VERSION_NAME: ${{ env.GITHUB_REF_NAME }}
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.ORG_GRADLE_PROJECT_MAVENCENTRALUSERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.ORG_GRADLE_PROJECT_MAVENCENTRALPASSWORD }}
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEY }}
ORG_GRADLE_PROJECT_signingInMemoryKeyId: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEYID }}
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGINMEMORYKEYPASSWORD }}
PUBLISH_STATE: Release
run: bash ./gradlew avifglide:publishAllPublicationsToMavenCentralRepository
57 changes: 57 additions & 0 deletions avifglide/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,8 +1,65 @@
import com.vanniktech.maven.publish.AndroidMultiVariantLibrary

plugins {
id("com.android.library")
id("org.jetbrains.kotlin.android")
id("kotlin-kapt")
id("maven-publish")
id("signing")
id("com.vanniktech.maven.publish") version "0.34.0"
}

mavenPublishing {
if (System.getenv("PUBLISH_STATE") == "Release") {
signAllPublications()
}
}

mavenPublishing {
configure(
AndroidMultiVariantLibrary(
sourcesJar = true,
publishJavadocJar = true,
)
)

if (System.getenv("PUBLISH_STATE") == "Release") {
coordinates("io.github.awxkee", "avif-coder-glide", System.getenv("VERSION_NAME") ?: "0.0.10")
} else {
coordinates("io.github.awxkee", "avif-coder-glide", "0.0.10")
}

pom {
name.set("AVIF Coder")
description.set("AVIF encoder/decoder for Android")
inceptionYear.set("2025")
url.set("https://github.com/awxkee/avif-coder")
licenses {
license {
name.set("The Apache License, Version 2.0")
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
distribution.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
}
license {
name.set("The 3-Clause BSD License")
url.set("https://opensource.org/license/bsd-3-clause")
description.set("https://opensource.org/license/bsd-3-clause")
}
}
developers {
developer {
id.set("awxkee")
name.set("Radzivon Bartoshyk")
url.set("https://github.com/awxkee")
email.set("[email protected]")
}
}
scm {
url.set("https://github.com/awxkee/avif-coder-glide")
connection.set("scm:git:[email protected]:awxkee/avif-coder-glide.git")
developerConnection.set("scm:git:ssh://[email protected]/awxkee/avif-coder-glide.git")
}
}
}

task("androidSourcesJar", Jar::class) {
Expand Down