Skip to content

marcel-st/droidbert

Repository files navigation

Droidbert

Android app for reading Dilbert comics with a native interface backed by the Daily Dilbert image API.

Requirements

  • Android Studio (latest stable)
  • Android SDK 35
  • JDK 17

Run

  1. Open this folder in Android Studio.
  2. Let Gradle sync complete.
  3. Run the app configuration on an emulator or device.

Behavior

  • Loads comic images directly from https://dilbert.xo.nl/api/current.php (compatible with date/latest queries).
  • Automatically falls back to legacy get_comics.php + /comics/... endpoints when API endpoints are unavailable on a host.
  • Sends browser-like request headers for API and legacy requests to improve compatibility with servers/CDNs that filter bot-like clients.
  • Shows a native comic reader UI optimized for phones.
  • Supports Latest, date picker lookup, and previous/next comic navigation.
  • Supports swipe navigation on the comic area:
    • swipe left = next comic, swipe right = previous comic (default)
    • optional Invert swipe direction setting swaps this behavior
  • When loading another comic, the reader resets scroll position back to the top.
  • Decodes and renders GIF comic images natively.
  • Includes a Settings screen to change API base URL at runtime.
  • Supports two comic display modes via Settings:
    • Auto-split comic into panels (default): detects separator bars/gutters and renders panels in reading order (top-left to bottom-right).
    • Full image: always renders the original comic image without splitting.
  • First launch starts at 1989-04-16; subsequent launches resume the user's last viewed comic.

App icon

  • Launcher icon uses logo/droidbert.webp as source image.
  • App resources reference app/src/main/res/drawable/droidbert.webp with adaptive and legacy launcher mappings.
  • Foreground logo is centered with 20dp inset padding via app/src/main/res/drawable/ic_launcher_logo_inset.xml.
  • Logo WebP assets are kept free of embedded EXIF/XMP/ICC metadata for release compliance.

Download APK (no local build required)

  1. Open the GitHub Releases page for this repository.
  2. Download the droidbert-<version>.apk asset from the latest release.
  3. Install it on your Android device.

If Android reports the APK is blocked by an installed app, the installed app was signed with a different key. Uninstall the currently installed Droidbert once, then install the new APK.

For local development builds, release now falls back to debug signing when release keystore environment variables are not configured, so locally built release APKs remain installable.

Release process (tagging + APK asset)

This repository includes a GitHub Actions workflow at .github/workflows/release-apk.yml.

  • Trigger: push a tag matching v* (for example v0.1.0).
  • Result: GitHub builds a signed release APK and creates a release with droidbert-<version>.apk attached.

Required GitHub repository secrets for signing:

  • ANDROID_KEYSTORE_BASE64 (base64-encoded keystore file)
  • ANDROID_KEYSTORE_PASSWORD
  • ANDROID_KEY_ALIAS
  • ANDROID_KEY_PASSWORD

Example commands:

git tag -a v0.3.0 -m "Release v0.3.0"
git push origin v0.3.0

Automated version bump + changelog workflow

  • Run the Bump Version workflow (.github/workflows/bump-version.yml) manually from GitHub Actions.
  • Provide a semantic version (example: 0.2.0).
  • The workflow will:
    • increment versionCode
    • set versionName
    • add a new dated section in CHANGELOG.md
    • create and push tag v<version>

Changelog/version guard workflow

  • The Version and Changelog Guard workflow (.github/workflows/version-changelog-guard.yml) enforces:
    • CHANGELOG.md must be updated when app/build.gradle.kts changes in PRs
    • CHANGELOG.md must include ## [Unreleased]
    • pushed release tags (v*) must match versionName
    • changelog must contain the matching version section
    • completed releases must include APK asset droidbert-<version>.apk

F-Droid metadata

This repository contains metadata and helper files to simplify submission to the official F-Droid fdroiddata repository.

  • App metadata template: fdroid/com.droidbert.yml
  • Submission checklist and MR text: fdroid/SUBMISSION.md
  • Quickstart commands: fdroid/FDROIDDATA_QUICKSTART.md
  • Helper script to copy metadata into a local fdroiddata checkout: fdroid/copy-to-fdroiddata.sh
  • Fastlane listing metadata: fastlane/metadata/android/en-US/

Keep Builds, CurrentVersion, and CurrentVersionCode in fdroid/com.droidbert.yml aligned with app/build.gradle.kts and the latest release tag. Use AutoUpdateMode: Version with UpdateCheckMode: Tags for tag-based F-Droid update detection. Current metadata is aligned to v0.3.12 / versionCode 27.

Example helper usage:

./fdroid/copy-to-fdroiddata.sh /path/to/fdroiddata

Changelog

See CHANGELOG.md for release notes.

Testing

Run local JVM unit tests:

./gradlew :app:testDebugUnitTest

Run Android instrumentation tests (emulator/device required):

./gradlew :app:connectedDebugAndroidTest

Maintenance policy: every functional or workflow/configuration change should include matching updates to README.md and CHANGELOG.md.

About

Android app for my Daily Dilbert website

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors