Skip to content

Commit 0273f51

Browse files
committed
version update
1 parent b796264 commit 0273f51

File tree

4 files changed

+126
-2
lines changed

4 files changed

+126
-2
lines changed
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Create Release
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
create-release:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v4
18+
with:
19+
fetch-depth: 0
20+
21+
- name: Get tag name
22+
id: tag
23+
run: echo "tag=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
24+
25+
- name: Generate release notes
26+
id: release_notes
27+
run: |
28+
# Get the previous tag to generate changelog
29+
PREVIOUS_TAG=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "")
30+
31+
if [ -n "$PREVIOUS_TAG" ]; then
32+
echo "## What's Changed" > release_notes.md
33+
echo "" >> release_notes.md
34+
35+
# Get commits since previous tag
36+
git log --pretty=format:"- %s" ${PREVIOUS_TAG}..HEAD >> release_notes.md
37+
38+
echo "" >> release_notes.md
39+
echo "## Full Changelog" >> release_notes.md
40+
echo "**Full Changelog**: https://github.com/${{ github.repository }}/compare/${PREVIOUS_TAG}...${{ steps.tag.outputs.tag }}" >> release_notes.md
41+
else
42+
echo "## What's Changed" > release_notes.md
43+
echo "" >> release_notes.md
44+
echo "🎉 Initial release of ${{ steps.tag.outputs.tag }}" >> release_notes.md
45+
fi
46+
47+
- name: Create Release
48+
env:
49+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
50+
run: |
51+
# Create release with notes
52+
gh release create "${{ steps.tag.outputs.tag }}" \
53+
--title "${{ steps.tag.outputs.tag }}" \
54+
--notes-file release_notes.md
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: release-maven
2+
3+
on:
4+
push:
5+
tags:
6+
- '*' # publish on any tag (e.g., 1.0.2 or v1.0.2)
7+
workflow_dispatch:
8+
9+
jobs:
10+
publish:
11+
runs-on: ubuntu-latest
12+
timeout-minutes: 30
13+
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v4
17+
18+
- name: Derive version from tag
19+
id: ver
20+
shell: bash
21+
run: |
22+
TAG="${GITHUB_REF##*/}" # "1.2.3" or "v1.2.3"
23+
VERSION="${TAG#v}" # strip leading 'v' if present
24+
if [[ -z "$VERSION" ]]; then
25+
echo "Tag is empty → cannot compute version"; exit 1
26+
fi
27+
echo "VERSION=$VERSION" >> "$GITHUB_OUTPUT"
28+
29+
- name: Set up JDK and import GPG key
30+
uses: actions/setup-java@v4
31+
with:
32+
distribution: temurin
33+
java-version: '21'
34+
cache: gradle
35+
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
36+
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }}
37+
38+
# ---- Sanity checks ----
39+
- name: Sanity - show derived version / Java / Gradle
40+
run: |
41+
echo "Derived version: ${{ steps.ver.outputs.VERSION }}"
42+
java -version
43+
./gradlew --version
44+
45+
- name: Sanity - list imported GPG secret keys
46+
run: gpg --list-secret-keys --keyid-format=long
47+
# -----------------------
48+
49+
- name: Configure Gradle (Central + signing via gpg)
50+
shell: bash
51+
run: |
52+
mkdir -p ~/.gradle
53+
cat > ~/.gradle/gradle.properties <<'EOF'
54+
# Sonatype Central Portal token credentials
55+
mavenCentralUsername=${{ secrets.MAVEN_CENTRAL_USERNAME }}
56+
mavenCentralPassword=${{ secrets.MAVEN_CENTRAL_PASSWORD }}
57+
58+
# Use system gpg imported by setup-java
59+
signing.gnupg.useGpgCmd=true
60+
signing.gnupg.keyName=${{ secrets.GPG_KEY_ID }}
61+
signing.gnupg.passphrase=${{ secrets.GPG_PASSPHRASE }}
62+
63+
# Let the Vanniktech plugin auto-release after upload
64+
mavenCentralAutomaticPublishing=true
65+
EOF
66+
67+
- name: Build (AAR + sources/javadoc jars)
68+
run: ./gradlew clean assembleRelease --no-daemon
69+
70+
- name: Publish to Maven Central (auto-release)
71+
run: ./gradlew -Pversion=${{ steps.ver.outputs.VERSION }} publishToMavenCentral --no-daemon --stacktrace

Example/app/src/main/AndroidManifest.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
xmlns:tools="http://schemas.android.com/tools">
44

55
<application
6-
android:networkSecurityConfig="@xml/network_security_config"
76
android:allowBackup="true"
87
android:dataExtractionRules="@xml/data_extraction_rules"
98
android:fullBackupContent="@xml/backup_rules"

deeponesdk/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,6 @@ android {
104104
}
105105

106106
dependencies {
107-
implementation("io.deepone.sdk:deeponenetworking:1.0.15")
107+
implementation("io.deepone.sdk:deeponenetworking:1.0.16")
108108
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.3")
109109
}

0 commit comments

Comments
 (0)