-
Notifications
You must be signed in to change notification settings - Fork 10
Update README.md #21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update README.md #21
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,34 +2,42 @@ | |
|
|
||
| Android SDK for ThunderID. Provides authentication and user management for native Android applications. | ||
|
|
||
| - [Quickstart](https://thunderid.dev/docs/next/getting-started/connect-your-application/android/) | ||
| - [API reference](https://thunderid.dev/docs/next/sdks/android/overview/) | ||
|
|
||
| ## Installation | ||
|
|
||
| ### Gradle | ||
|
|
||
|  | ||
|
|
||
| Make sure your project's `settings.gradle.kts` includes JitPack: | ||
|
|
||
| ```kotlin | ||
| dependencies { | ||
| implementation("dev.thunderid:android:0.1.0") | ||
| dependencyResolutionManagement { | ||
| repositories { | ||
| maven("https://jitpack.io") | ||
| } | ||
| } | ||
| ``` | ||
|
|
||
| For Jetpack Compose UI components, also add: | ||
|
|
||
| ```kotlin | ||
| dependencies { | ||
| implementation("dev.thunderid:compose:0.1.0") | ||
| implementation("com.github.thunder-id.android-sdks:android:<latest-release-tag>") | ||
| } | ||
| ``` | ||
|
|
||
| Make sure your project's `settings.gradle.kts` includes the ThunderID Maven repository: | ||
| For Jetpack Compose UI components, also add: | ||
|
|
||
| ```kotlin | ||
| dependencyResolutionManagement { | ||
| repositories { | ||
| maven("https://maven.thunderid.dev/releases") | ||
| } | ||
| dependencies { | ||
| implementation("com.github.thunder-id.android-sdks:compose:<latest-release-tag>") | ||
| } | ||
|
Comment on lines
24
to
35
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -e
printf '%s\n' '--- README.md ---'
sed -n '1,55p' README.md
printf '%s\n' '--- Gradle-related files ---'
git ls-files | grep -E '(^|/)(settings\.gradle(\.kts)?|build\.gradle(\.kts)?|gradle\.properties)$|(^|/)gradle/' || true
printf '%s\n' '--- Repository and dependency declarations ---'
rg -n --glob '!*build*' 'google\(\)|mavenCentral\(\)|jitpack|implementation\(|compose|android-sdks' .
printf '%s\n' '--- README newline status ---'
python3 - <<'PY'
from pathlib import Path
p = Path("README.md")
b = p.read_bytes()
print("exists:", p.exists())
print("ends_with_one_newline:", b.endswith(b"\n") and not b.endswith(b"\n\n"))
print("last_bytes:", repr(b[-8:]))
PYRepository: thunder-id/android-sdks Length of output: 50381 🏁 Script executed: #!/bin/bash
set -e
printf '%s\n' '--- settings.gradle.kts ---'
cat -n settings.gradle.kts
printf '%s\n' '--- root build.gradle.kts ---'
cat -n build.gradle.kts
printf '%s\n' '--- sample dependency declarations ---'
rg -n -C 3 'implementation\(|api\(|project\(' samples/quickstart/build.gradle.kts
printf '%s\n' '--- Gradle project declarations ---'
rg -n 'include|includeBuild|project\(|group\s*=|publishing|maven-publish|archivesBaseName|artifactId' \
settings.gradle.kts build.gradle.kts gradle.properties samples/quickstart/settings.gradle.kts \
samples/quickstart/build.gradle.kts || true
printf '%s\n' '--- README trailing bytes ---'
python3 - <<'PY'
from pathlib import Path
b = Path("README.md").read_bytes()
print(repr(b[-16:]))
print("exactly_one_final_newline:", b.endswith(b"\n") and not b.endswith(b"\n\n"))
PYRepository: thunder-id/android-sdks Length of output: 4626 🌐 Web query:
💡 Result: To publish a single-module Android library on JitPack with custom Maven coordinates, you must configure the maven-publish plugin in your module's build file [1][2]. JitPack detects your library by building your project and looking for the artifacts produced during the build process [3][4][5]. Key steps to configure custom groupId and artifactId: 1. Enable the maven-publish plugin in your library's build.gradle or build.gradle.kts file [1][6]. 2. Configure the publishing block to specify your desired groupId, artifactId, and version [1][6][2]. 3. Ensure the project can run the task publishToMavenLocal successfully [2][5]. Example configuration in build.gradle (Groovy): plugins { id 'com.android.library' id 'maven-publish' } publishing { publications { release(MavenPublication) { groupId = 'com.yourcustom.group' artifactId = 'your-custom-artifact' version = '1.0.0' afterEvaluate { from components.release } } } } Important considerations: - Default Coordinates: If you do not explicitly define a groupId, JitPack defaults to com.github.Username:RepositoryName [7][8]. - Custom Domain: If you wish to use your own domain name as the groupId (e.g., com.yourcompany), you must map your domain to your GitHub organization using a DNS TXT record (git.yourcompany.com -> https://github.com/yourcompany) and verify it through the JitPack website [3][9][10]. - Build Requirements: JitPack builds tagged releases from your Git repository [4]. Ensure you have created a tag (e.g., v1.0.0) in your repository and that your project includes a Gradle wrapper [4][5]. - Consumption: Once built, you can include your library in other projects by adding the JitPack repository to your settings.gradle or build.gradle and specifying the dependency using your custom coordinates: implementation 'com.yourcustom.group:your-custom-artifact:1.0.0' [4][2]. Citations:
🏁 Script executed: #!/bin/bash
set -e
printf '%s\n' '--- JitPack metadata for repository-style coordinates ---'
for url in \
'https://jitpack.io/com/github/thunder-id/android-sdks/maven-metadata.xml' \
'https://jitpack.io/com/github/thunder-id/android-sdks/android/maven-metadata.xml' \
'https://jitpack.io/com/github/thunder-id/android-sdks/compose/maven-metadata.xml' \
'https://jitpack.io/com/github/thunder-id/android-sdks/0.2.0/android-sdks-0.2.0.pom' \
'https://jitpack.io/com/github/thunder-id/android-sdks/0.2.0/android-0.2.0.pom'
do
printf '\nURL: %s\n' "$url"
curl -L --max-time 15 -sS -o /tmp/jitpack-response -w 'HTTP %{http_code}\n' "$url"
head -c 1000 /tmp/jitpack-response
printf '\n'
doneRepository: thunder-id/android-sdks Length of output: 3520 🏁 Script executed: #!/bin/bash
set -e
for version in 0.2.0 v0.2.0 0.3.1 v0.3.1 v1.0.0; do
for artifact in android-sdks android compose; do
url="https://jitpack.io/com/github/thunder-id/android-sdks/${version}/${artifact}-${version}.pom"
status="$(curl -L --max-time 15 -sS -o /tmp/jitpack-pom -w '%{http_code}' "$url")"
printf '%-7s %-12s HTTP %s ' "$version" "$artifact" "$status"
if [ "$status" = 200 ]; then
sed -nE 's/.*<(groupId|artifactId|version)>([^<]+).*/\1=\2/p' /tmp/jitpack-pom | head -n 3 | tr '\n' ' '
fi
printf '\n'
done
done
printf '%s\n' '--- Latest release metadata ---'
curl -L --max-time 15 -sS \
'https://api.github.com/repos/thunder-id/android-sdks/releases/latest' |
jq '{tag_name, name, draft, prerelease}'
printf '%s\n' '--- Current release tag tree indicators ---'
curl -L --max-time 15 -sS \
'https://api.github.com/repos/thunder-id/android-sdks/git/refs/tags/v1.0.0' |
jq '{ref, object}'Repository: thunder-id/android-sdks Length of output: 1159 Use the single-module JitPack coordinate. The dependencies {
implementation("com.github.thunder-id:android-sdks:<latest-release-tag>")
}🤖 Prompt for AI Agents |
||
| ``` | ||
|
|
||
| > [!NOTE] | ||
| > Replace `<latest-release-tag>` with the [latest release tag](https://github.com/thunder-id/android-sdks/releases) of the `android-sdks` repository. | ||
|
|
||
| ## License | ||
|
|
||
| This project is licensed under the [Apache License 2.0](https://github.com/thunder-id/thunderid/blob/main/LICENSE) | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: thunder-id/android-sdks
Length of output: 9351
🏁 Script executed:
Repository: thunder-id/android-sdks
Length of output: 6191
Keep the standard Gradle repositories in this example.
If users copy this block as their complete repository configuration, AndroidX and Compose dependencies cannot resolve. Keep
google()andmavenCentral(), then add JitPack.Proposed fix
dependencyResolutionManagement { repositories { + google() + mavenCentral() maven("https://jitpack.io") } }📝 Committable suggestion
🤖 Prompt for AI Agents