{"id":13609167,"url":"https://github.com/devrath/Distance-Tracker","last_synced_at":"2025-04-12T19:33:32.716Z","repository":{"id":65098778,"uuid":"570594617","full_name":"devrath/Distance-Tracker","owner":"devrath","description":"🗺️ Tacking the user distance traveled and time taken using the google maps API","archived":false,"fork":false,"pushed_at":"2023-08-09T12:28:12.000Z","size":37094,"stargazers_count":9,"open_issues_count":0,"forks_count":4,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-11-07T15:43:51.425Z","etag":null,"topics":["android","android-location","clean-architecture","clean-architecture-android","clean-code","dependencyinjection","foreground-service","fusedlocationapi","google-maps","hilt","kotlin","kotlin-android","location-permissions","mvvm","mvvm-architecture","usecase"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/devrath.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2022-11-25T15:11:36.000Z","updated_at":"2024-08-22T03:47:20.000Z","dependencies_parsed_at":"2024-01-16T23:41:05.406Z","dependency_job_id":null,"html_url":"https://github.com/devrath/Distance-Tracker","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devrath%2FDistance-Tracker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devrath%2FDistance-Tracker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devrath%2FDistance-Tracker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devrath%2FDistance-Tracker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devrath","download_url":"https://codeload.github.com/devrath/Distance-Tracker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248621512,"owners_count":21134868,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","android-location","clean-architecture","clean-architecture-android","clean-code","dependencyinjection","foreground-service","fusedlocationapi","google-maps","hilt","kotlin","kotlin-android","location-permissions","mvvm","mvvm-architecture","usecase"],"created_at":"2024-08-01T19:01:32.962Z","updated_at":"2025-04-12T19:33:30.874Z","avatar_url":"https://github.com/devrath.png","language":"Kotlin","funding_links":["https://www.buymeacoffee.com/devrath"],"categories":["Kotlin"],"sub_categories":[],"readme":"![cover](https://github.com/devrath/Distance-Tracker/blob/main/Assets/Banner/banner.jpeg)\n\n\n\n\u003ca href=\"https://play.google.com/store/apps/details?id=com.twinvave.godiswithme\"\u003e\u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/Images/google-play-store.png\" align=\"right\"\u003e\u003c/a\u003e\n\n\n# Distance-Tracker 🧞‍\n[![Android Best practices](https://img.shields.io/badge/Android-best--practices-red)](https://www.android.com/intl/en_in/what-is-android/) \n[![Kotlin](https://img.shields.io/badge/Kotlin-1.6.10-brightgreen)](https://kotlinlang.org/) \n[![Coroutines](https://img.shields.io/badge/Coroutines-1.6.0-red)](https://kotlinlang.org/docs/reference/coroutines-overview.html) \n[![DaggerHilt](https://img.shields.io/badge/DaggerHilt-2.40-blue)](https://developer.android.com/training/dependency-injection/hilt-android) \n[![Firebase](https://img.shields.io/badge/Firebase-30.2.0-blueviolet)](https://firebase.google.com/) \n[![Timber](https://img.shields.io/badge/Timber-5.0.1-blue)](https://github.com/JakeWharton/timber) \n[![Orhanobut](https://img.shields.io/badge/orhanobut-2.2.0-lightgrey)](https://github.com/orhanobut/logger) \n[![Google Material](https://img.shields.io/badge/Google%20Material-1.4.0-3D3635)](https://material.io/develop/android/docs/getting-started) \n[![Crashlytics](https://img.shields.io/badge/Crashlytics-2.9.1-3B9C9C)](https://firebase.google.com/docs/crashlytics) \n[![Fused Location Service](https://img.shields.io/badge/Location-fused--location--service-orange)](https://developers.google.com/location-context/fused-location-provider)\n[![OkHttp](https://img.shields.io/static/v1?label=Okhttp\u0026message=4.10.0\u0026color=red)](https://square.github.io/okhttp/) \n[![OkHttp-interceptors](https://img.shields.io/static/v1?label=Okhttp-interceptors\u0026message=4.10.0\u0026color=brightgreen)](https://square.github.io/okhttp/features/interceptors/)\n[![Kotlin-Serialization](https://img.shields.io/static/v1?label=Okhttp\u0026message=1.7.20\u0026color=blue)](https://github.com/Kotlin/kotlinx.serialization) \n\n\n\n\n## **`𝙰𝚛𝚌𝚑𝚒𝚝𝚎𝚌𝚝𝚞𝚛𝚎`** 🎈\n\n### `𝙱𝚕𝚘𝚌𝚔 𝙳𝚒𝚊𝚐𝚛𝚊𝚖`\n\u003cdiv align=\"center\"\u003e\n\u003cimg align=\"center\" height=\"500\" width=\"400\" src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/Architecture/projectstructure.drawio.png\"  alt=\"dev_logo\"/\u003e\n\u003c/div\u003e\n\n### `𝙼𝚅𝚅𝙼-𝙰𝚙𝚙𝚛𝚘𝚊𝚌𝚑`\n\u003cdiv align=\"center\"\u003e\n\u003cimg align=\"center\" height=\"500\" width=\"600\" src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/Architecture/MVVM.png\"  alt=\"dev_logo\"/\u003e\n\u003c/div\u003e\n\n#### **`𝚃𝚑𝚎 𝚊𝚛𝚌𝚑𝚒𝚝𝚎𝚌𝚝𝚞𝚛𝚎 𝚘𝚏 𝚝𝚑𝚎 𝚊𝚙𝚙𝚕𝚒𝚌𝚊𝚝𝚒𝚘𝚗 𝚒𝚜 𝚋𝚊𝚜𝚎𝚍, 𝚊𝚙𝚙𝚕𝚢 𝚊𝚗𝚍 𝚜𝚝𝚛𝚒𝚌𝚝𝚕𝚢 𝚌𝚘𝚖𝚙𝚕𝚒𝚎𝚜 𝚠𝚒𝚝𝚑 𝚎𝚊𝚌𝚑 𝚘𝚏 𝚝𝚑𝚎 𝚏𝚘𝚕𝚕𝚘𝚠𝚒𝚗𝚐 𝟻 𝚙𝚘𝚒𝚗𝚝𝚜`** 🐿️\n\n| `SlNo` | `Description` |\n| ------ | ------------- |\n|   `1`  | A single-activity architecture, using the [Navigation component](https://developer.android.com/guide/navigation/navigation-getting-started) to manage fragment operations. |\n|   `2`  | [Android architecture components](https://developer.android.com/topic/libraries/architecture/), part of Android Jetpack for give to project a robust design, testable and maintainable. |\n|   `3`  | Pattern [Model-View-ViewModel](https://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93viewmodel) (MVVM) facilitating a [separation](https://en.wikipedia.org/wiki/Separation_of_concerns) of development of the graphical user interface. |\n|   `4`  | [S.O.L.I.D](https://en.wikipedia.org/wiki/SOLID) design principles intended to make software designs more understandable, flexible and maintainable. |\n|   `5`  | [Modular app architecture](https://proandroiddev.com/build-a-modular-android-app-architecture-25342d99de82) allows to be developed features in isolation, independently from other features. |\n\n#### **`𝙼𝚘𝚍𝚞𝚕𝚊𝚛𝚒𝚣𝚊𝚝𝚒𝚘𝚗 𝚜𝚝𝚛𝚊𝚝𝚎𝚐𝚒𝚎𝚜 𝚞𝚜𝚎𝚍`** 🦨 \n\n| **`Name`** | **`Description`** |\n| ---------- | ----------------- |\n| **`Reusability`** | Keeping code reusable so same code snippets are utilized in different parts of the code |\n| **`Parallel Building`** | Modular approach reduces the build time |\n| **`Strict visibility control`** | Modules restrict to expose dedicated components and access to other layers, so it prevents they're being used outside the module |\n| **`Decentralized focusing`** | Each developer team can assign their dedicated module and they can focus on their own modules |\n\n## **`𝙳𝚎𝚖𝚘 𝚘𝚏 𝚝𝚑𝚎 𝚙𝚛𝚘𝚓𝚎𝚌𝚝`** 💡\nThis application is used to track the user distance traveled and the time taken to travel the distance.\n\n| **`Features with Description`** | **`Wiki`** | **`Demo`** |\n| ------------------------------- | ---------- | ---------- |\n| **`Location-Tracking`** : With this feature users can start the tracking from a source and travel to destination. Then measure the `distance travelled` and `time taken` for the journey with a visual display on the map using hte `polyline`. Users will be able to `track the distance` even when the app is not in the foreground or background using a `foreground service`. | [Documentation](https://github.com/devrath/Distance-Tracker/wiki/%F0%9D%99%BB%F0%9D%9A%98%F0%9D%9A%8C%F0%9D%9A%8A%F0%9D%9A%9D%F0%9D%9A%92%F0%9D%9A%98%F0%9D%9A%97-%F0%9D%9A%83%F0%9D%9A%9B%F0%9D%9A%8A%F0%9D%9A%8C%F0%9D%9A%94%F0%9D%9A%92%F0%9D%9A%97%F0%9D%9A%90-%F0%9F%A7%AD) | \u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/ScreenGif/Demo.gif\" width=\"160\" height=\"330\"/\u003e |\n| [**`Splash API`**](https://developer.android.com/develop/ui/views/launch/splash-screen): With this API there is no need of creating a separate activity to customise the splash screen. The system will automatically create one for you. It also allows you to have a new launch animation for your apps and ability to perform a long running operation. |  | \u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/ScreenGif/splash.gif\" width=\"160\" height=\"330\"/\u003e |\n| [**`In-App updates`**](https://developer.android.com/guide/playcore/in-app-updates): Using this API, users will be able to update the application in an eligant way thus keeping the app always up-to-date. | [Documentation](https://developer.android.com/guide/playcore/in-app-updates/kotlin-java) | \u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/ScreenGif/updates.gif\" width=\"160\" height=\"330\"/\u003e |\n| [**`App-reviews`**](https://developer.android.com/guide/playcore/in-app-review): This API lets you prompt users to submit `Play Store ratings` and `reviews` without the inconvenience of leaving your app. |  |  |\n| **`Network Observer`**: This is used to observe the network change if connected/disconnected to user | [Documentation](https://github.com/devrath/droid-network-observer) | \u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/ScreenGif/network_observer.gif\" width=\"160\" height=\"330\"/\u003e |\n| **`Toggling dark/light mode from app`**: This application supports system dark/light mode along with it user can force the toggling of modes in android | [Documentation](https://github.com/devrath/android-congenial-fortnight-darktheme) | \u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/ScreenGif/dark_light_mode.gif\" width=\"160\" height=\"330\"/\u003e |\n| **`Changing the map style`**: We can dynamically change the map style of android to provide a different user experience |  | \u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/ScreenGif/switch_map_types.gif\" width=\"160\" height=\"330\"/\u003e |\n\n## **`Useful learnings`** 💡\n* [_**`Publisher subscriber pattern using flow API`**_](https://medium.com/@devrath.dev595/publisher-subscriber-using-shared-flow-api-e12baf32113e)\n* [_**`Kotlin serilization for serilization of API and model objects`**_](https://github.com/devrath/KotlinSerialization)\n* [_**`Okhttp interceptors to modify the netwrok requests`**_](https://github.com/devrath/fluffy-okhttp-interceptors)\n* [_**`Scoped storage in android`**_](https://github.com/devrath/refactored-android-scoped-storage)\n* [_**`Setting UI using view-groups`**_](https://github.com/devrath/DroidCustomUi)\n* [_**`Storing data offline in application`**_](https://github.com/devrath/droid-offline-application)\n* [_**`Elegant way to handle recycler view on-click`**_](https://medium.com/@devrath.dev595/an-elegant-way-to-handle-recycler-view-item-on-click-in-android-d011c95e2953)\n\n\n\n### `𝙳𝚎𝚙𝚎𝚗𝚍𝚎𝚗𝚌𝚒𝚎𝚜`🧵\n\n* [Jetpack-Androidx](https://developer.android.com/jetpack/androidx): Major improvement to the original Android Support Library, which is no longer maintained.\n* [View-Binding](https://developer.android.com/topic/libraries/view-binding): Allows you to more easily write code that interacts with views. An instance of a binding class contains direct references to all views that have an ID in the corresponding layout.\n* [Lifecycle](https://developer.android.com/topic/libraries/architecture/lifecycle): Perform actions in response to a change in the lifecycle status of another component, such as activities and fragments.\n* [LiveData](https://developer.android.com/topic/libraries/architecture/livedata): lifecycle-aware, meaning it respects the lifecycle of other app components, such as activities, fragments, or services.\n* [Navigation](https://developer.android.com/guide/navigation/): helps you implement navigation, from simple button clicks to more complex patterns, such as app bars and the navigation drawer.\n* [Timber](https://github.com/JakeWharton/timber): a logger with a small, extensible API which provides utility on top of Android's normal Log class.\n* [DataStore](https://developer.android.com/topic/libraries/architecture/datastore?gclid=CjwKCAiAkrWdBhBkEiwAZ9cdcJQtRe-hDXI0aPKf4u8n0EfU-xh1ODfQ80ImOVEPKgRHaVmwGCrb-xoCJQwQAvD_BwE\u0026gclsrc=aw.ds): iData storage solution that allows you to store key-value pairs.\n* [Fused location provider](https://developers.google.com/location-context/fused-location-provider): Get location data for your app based on combined signals from the device sensors using a battery-efficient API.\n* [Google play core](https://developer.android.com/guide/playcore): Download additional language resources, Manage delivery of feature modules, Manage delivery of asset packs, Trigger in-app updates, Request in-app reviews\n* [Coroutines](https://developer.android.com/kotlin/coroutines?gclid=CjwKCAiAkrWdBhBkEiwAZ9cdcD5t8r7gogrF9MOUjglqJc0sx55z13IfZldSaHt8Wm1c2qLg7gwSlBoCKq8QAvD_BwE\u0026gclsrc=aw.ds): A coroutine is a concurrency design pattern that you can use on Android to simplify code that executes asynchronously\n\n\n\n### `𝙲𝚘𝚍𝚎 𝚜𝚝𝚢𝚕𝚎`🪀\n\nTo maintain the style and quality of the code, are used the bellow static analysis tools. \n\n| Tools                                                   | Config file                                                                       | Check command             | Fix command               |\n|---------------------------------------------------------|----------------------------------------------------------------------------------:|---------------------------|---------------------------|\n| [detekt](https://github.com/arturbosch/detekt)          | [/.detekt](https://github.com/VMadalin/kotlin-sample-app/tree/master/.detekt)     | `./gradlew detekt`        | -                         |\n| [ktlint](https://github.com/pinterest/ktlint)           | -                                                                                 | `./gradlew ktlint`        | `./gradlew ktlintFormat`  |\n| [spotless](https://github.com/diffplug/spotless)        | [/.spotless](https://github.com/VMadalin/kotlin-sample-app/tree/master/.spotless) | `./gradlew spotlessCheck` | `./gradlew spotlessApply` |\n| [lint](https://developer.android.com/studio/write/lint) | [/.lint](https://github.com/VMadalin/kotlin-sample-app/tree/master/.lint)         | `./gradlew lint`          | -                         |\n\n## **`𝚃𝚎𝚌𝚑 𝚜𝚝𝚊𝚌𝚔`** 🏗️️ \n\n| What            | How                        |\n|----------------\t|------------------------------\t|\n| 🎭 𝚄𝚜𝚎𝚛 𝙸𝚗𝚝𝚎𝚛𝚏𝚊𝚌𝚎 (𝙰𝚗𝚍𝚛𝚘𝚒𝚍)   | [𝙹𝚎𝚝𝚙𝚊𝚌𝚔 𝙲𝚘𝚖𝚙𝚘𝚜𝚎](https://developer.android.com/jetpack/compose) , [𝙰𝚌𝚝𝚒𝚟𝚒𝚝𝚢+𝚇𝙼𝙻](https://developer.android.com/develop/ui/views/layout/declaring-layout)               |\n| 🏗 𝙰𝚛𝚌𝚑𝚒𝚝𝚎𝚌𝚝𝚞𝚛𝚎    | [𝙲𝚕𝚎𝚊𝚗 𝙰𝚛𝚌𝚑𝚒𝚝𝚎𝚌𝚝𝚞𝚛𝚎](https://blog.cleancoder.com/uncle-bob/2012/08/13/the-clean-architecture.html)                            |\n| 💉 𝙳𝙸 (𝙰𝚗𝚍𝚛𝚘𝚒𝚍)                | [𝙷𝚒𝚕𝚝](https://developer.android.com/training/dependency-injection/hilt-android)                        |\n| 🌊 𝙰𝚜𝚢𝚗𝚌            | [𝙲𝚘𝚛𝚘𝚞𝚝𝚒𝚗𝚎𝚜](https://kotlinlang.org/docs/coroutines-overview.html) + [Flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/)                |\n| 🌐 𝙳𝚊𝚝𝚊𝚋𝚊𝚜𝚎        | [𝚁𝚘𝚘𝚖](https://developer.android.com/jetpack/androidx/releases/room?gclid=Cj0KCQiAtbqdBhDvARIsAGYnXBN8WeUfoN8Ln5XfcNlF83mZZbJjiboM1DU95jgGawDZ5pfegpNQWOMaAtt0EALw_wcB\u0026gclsrc=aw.ds)                       |\n\n## **`𝙿𝚕𝚊𝚢𝚜𝚝𝚘𝚛𝚎 𝙳𝚘𝚠𝚗𝚕𝚘𝚊𝚍`** 🧰\n\u003ca href=\"https://play.google.com/store/apps/details?id=com.istudio.distancetracker\"\u003e\u003cimg src=\"https://github.com/devrath/Distance-Tracker/blob/main/Assets/Images/google-play.png\" height=\"75\"\u003e\u003c/a\u003e\n\n## **`𝚂𝚞𝚙𝚙𝚘𝚛𝚝`** ☕\nIf you feel like support me a coffee for my efforts, I would greatly appreciate it.\u003c/br\u003e\n\u003ca href=\"https://www.buymeacoffee.com/devrath\" target=\"_blank\"\u003e\u003cimg src=\"https://www.buymeacoffee.com/assets/img/custom_images/yellow_img.png\" alt=\"Buy Me A Coffee\" style=\"height: 41px !important;width: 174px !important;box-shadow: 0px 3px 2px 0px rgba(190, 190, 190, 0.5) !important;-webkit-box-shadow: 0px 3px 2px 0px rgba(190, 190, 190, 0.5) !important;\" \u003e\u003c/a\u003e\n\n## **`𝙲𝚘𝚗𝚝𝚛𝚒𝚋𝚞𝚝𝚎`** 🙋‍♂️\nRead [contribution guidelines](CONTRIBUTING.md) for more information regarding contribution.\n\n## **`𝙵𝚎𝚎𝚍𝚋𝚊𝚌𝚔`** ✍️ \nFeature requests are always welcome, [File an issue here](https://github.com/devrath/Distance-Tracker/issues/new).\n\n## **`𝙵𝚒𝚗𝚍 𝚝𝚑𝚒𝚜 𝚙𝚛𝚘𝚓𝚎𝚌𝚝 𝚞𝚜𝚎𝚏𝚞𝚕`** ? ❤️\nSupport it by clicking the ⭐ button on the upper right of this page. ✌️\n\n## **`𝙻𝚒𝚌𝚎𝚗𝚜𝚎`** ![Licence](https://img.shields.io/github/license/google/docsy) 🚔\nThis project is licensed under the Apache License 2.0 - see the [LICENSE](https://github.com/devrath/Distance-Tracker/blob/main/LICENSE) file for details\n\n\n\u003cp align=\"center\"\u003e\n\u003ca\u003e\u003cimg src=\"https://forthebadge.com/images/badges/built-for-android.svg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevrath%2FDistance-Tracker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevrath%2FDistance-Tracker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevrath%2FDistance-Tracker/lists"}