-
Notifications
You must be signed in to change notification settings - Fork 1
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
Multimodule #3
Open
OkelloSam21
wants to merge
37
commits into
main
Choose a base branch
from
multimodule
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Multimodule #3
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- create AndroidApplicationConventionPlugin that sets up the base configurations for application modules - apply necessary plugins (`com.android.application`, `org.jetbrains.kotlin.android`) - configure `ApplicationExtension` to set up Kotlin Android and target SDK.
- add compose configurations - add compose metric parameters - add compose dependencies
- Add `AndroidLibraryConventionPlugin` to manage common configurations for Android library modules. - Configure Kotlin and Android plugins. - Set `targetSdk`. - Implement optional library publishing via `configureAndroidLibraryPublish`. - Add `AndroidLibraryPublishMetaData` and `PublicationDetail` data classes for managing publication details.
- Add `AppConfig` object to define app-level configurations such as `compileSdk`, `minSdk`, `targetSdk`, and `minimumCoverageLimit`.
- configure base Kotlin options for JVM (non-Android) - enable experimental coroutines APIs, including Flow
- define dependency resolution management and version catalogs. - set root project name to "build_logic". - include ":convention" module.
- Introduce modularization by adding `auth`, `cart`, `products`, `profile`, and `wishlist` as feature modules. - Establish core Android and Kotlin dependencies across feature modules. - Setup necessary Android test cases, unit test cases and code coverage - Add build logic convention plugin to manage common configuration. - add `android`, `kotlin` plugins to each modules. - add `junit` and `androidx.junit` dependency to all modules. - add ProGuard rules to all modules. - add `androidx-core-ktx`, `androidx-appcompat` and `material` dependency to all modules. - update the gradle version to `8.6.1` and kotlin version `1.9.22` - updated the compose compiler to version `1.5.1`
- Add `AuthApiService` to handle user login and retrieving all users. - Add data classes for `LoginRequest`, `LoginResponse`, `UserResponseDto`, `Address`, `Geolocation`, and `Name` to manage API request and response. - Add `ProductApiService` for fetching products and categories. - Add data classes for `ProductDto` and `RatingDto`. - Add `CartApiService` for adding, updating, and deleting cart items. - Add `CartDto`, `CartProductDto`, and `UserCartResponseDto` for cart data management. - Add request DTOs `AddCartRequestDto` and `UpdateCartRequestDto` for API requests. - add `okhttp`, `kotlinx-serialization-json`, `retrofit` dependencies. - Add ProGuard rules and Gitignore. - add core module as dependency. - add unit test and android test files.
…pplicationComposeConventionPlugin - Update the `AndroidApplicationComposeConventionPlugin` to apply `com.android.convention.application` instead of `com.samuelokello.convention.application`.
- Move `AuthApiService` from `com.samuelokello.network.api` to `com.samuelokello.network.auth`. - Move `LoginResponse` from `com.samuelokello.shopspot.data.network.auth.response` to `com.samuelokello.network.auth.response`. - Update the package names for imports accordingly in the affected files.
…tion, and Room - Add `KotlinConventionPlugin` for Kotlin JVM projects with toolchain and test dependencies. - Add `KotlinxSerializationJsonPlugin` for Kotlin serialization with `kotlinx-serialization-json` dependency. - Add `AndroidHiltConventionPlugin` for Hilt integration with ksp and necessary dependencies. - Add `KspConventionPlugin` for Kotlin Symbol Processing - Add `RoomConventionPlugin` for room related dependencies - Update the plugin id for `androidApplicationCompose`, `androidApplication`, `androidLibrary`, `androidLibraryCompose` - Update the plugin implementation class to follow naming conventions
- Update Android Gradle Plugin (AGP) to `8.6.1`. - Update Kotlin version to `2.1.0`. - Update Compose BOM to `2025.01.01`. - Update Compose Compiler to `1.5.1` - Update Activity Compose to `1.10.0`. - Update Material Icons Extended Android to `1.7.7`. - Update Navigation Compose to `2.8.6`. - Update Room Compiler and Room to `2.6.1` - Update `kotlinx.serialization.json` to `2.0.21`. - Update `kotlinx-coroutines-test` to `1.9.0`. - Update `retrofit` to `2.11.0`. - Update `androidx.datastore-core-android` to `1.1.2`. - Add `androidx-hilt-navigation-compose` library. - Add `dagger-hilt` and `dagger-hilt-compiler` - Add `androidx-datastore-preferences`. - Add `kotlinx-coroutines-core` - Add ksp plugin and set version. - Add `compose-compiler` plugin. - Add `samuelokello-android-hilt` custom plugin. - update the name of android and kotlin plugin to `com-android-application`, `org-jetbrains-kotlin-android`, `com-android-library`
- Remove `UserResponseDto` as it is not needed. - Introduce `ExampleUnitTest` for local unit tests. - Introduce `ExampleInstrumentedTest` for Android instrumented tests. - Add `.gitignore` to ignore build files. - Create `CoreModule` for dependency injection with Hilt, including `AuthPreferences` via DataStore. - Add `Result` sealed class for handling operation results. - Add `UserData` to store user data for serialization. - Add `Constants` for various project constants. - Add `core` module dependencies and plugins including kotlin serialization and datastore.
- Move Room database, entities, and DAOs to a dedicated `database` module. - Create `ProductDao`, `UserDao`, and `UserCartDao` in the `database` module. - Create `ProductEntity`, `UserEntity`, and `UserCartEntity` within the `database` module. - Add `DatabaseModule` for dependency injection of the database and DAOs. - Implement `ShopSpotDatabase` as the main database class. - Add a `CartProductConverter` to handle custom type conversions. - Migrate `ProductEntityMapper` to `data` module. - Add `AndroidManifest.xml` and `build.gradle.kts` in database module. - Add `.gitignore` to ignore the build folder in `database` module. - Add `consumer-rules.pro` and `proguard-rules.pro` for managing project specific rules. - Update `ProductItem` composable to use `core` module model.
- Add `AuthPreferences` to manage user authentication data using DataStore. - Remove `Product` data class from the `app` module and add it in the `core` module. - Introduce `RoomConventionPlugin` to manage Room database dependencies, including runtime, KTX, and compiler. - Configure Room dependencies for Android and Java library modules. - Apply the KSP plugin to handle annotation processing for Room.
- Add `RoomConventionPlugin` to manage Room database dependencies. - Apply the KSP plugin for Room annotation processing. - Add dependencies for `androidx.room.runtime`, `androidx.room.ktx`, and `androidx.room.compiler`.
- Add `RoomConventionPlugin` to manage Room database dependencies. - Apply the KSP plugin for Room annotation processing. - Add dependencies for `androidx.room.runtime`, `androidx.room.ktx`, and `androidx.room.compiler`.
…sses - Rename `database` module to `local`. - Move `ShopSpotDatabase`, DAOs (`ProductDao`, `UserCartDao`, `UserDao`), and entities (`ProductEntity`, `UserCartEntity`, `User`) to the `local` module. - Update package names of database classes and related classes to `com.samuelokello.local`. - Create `.gitignore` file in `local` module to ignore build folder. - Create `AndroidManifest.xml` in `local` module. - Create `consumer-rules.pro` in `local` module.
- Move `LoginRequest`, `UserResponseDto`, `Address`, `Geolocation`, `CartDto`, `CartProductDto`, `UserCartResponseDto`, `Name` , and `ProductDto` to the `network` module. - Delete `Address`, `AuthApiService`, `CartDto`, `CartProductDto`, `Geolocation`, `LoginRequest`, `LoginResponse`, `ProductApiService`, `ProductDto` , `RatingDto`, `UserCartResponseDto`, and `UserResponseDto` from the `app` module. - Move `LoginResponse`, `AuthApiService`, `ProductApiService`, and `UserResponseDto` to `network` source. - Remove `build.gradle.kts` from `database` module. - Remove `build.gradle.kts` from the network module and replace with a new one in the sources. - Delete `CartDto`, `CartProductDto`, `UserCartResponseDto` from the network module. - Remove `LoginRequest`, `LoginResponse`, `Address`, and `Geolocation` from the `network` module. - Introduce `CartRepositoryImpl`, `LoginRepositoryImpl` and `ProductRepositoryImpl` to `network` source. - Add `NetworkModule` for dependency injection with Hilt, including `ProductApiService`, `CartApiService`, and `AuthApiService` via Retrofit. - Add a `.gitignore` file to ignore build files for network source. - Add `AndroidManifest.xml` in `network` source. - Add `consumer-rules.pro` and `proguard-rules.pro` for managing project specific rules in `network` source and `local` source. - Add `com.samuelokello.convention.sources` plugin.
- Remove `Cart`, `CartApiService`, and `CartItem` from `app` module as they are moved to `core` module. - Introduce `Screens` to `core` module for centralized navigation routes. - Add `UserCartMapper` in the `core` module to handle mapping for cart data. - Create `UserCart` data class to core module for data mapping. - Remove `ShopSpotContainer`, `User`, and `UserCart` classes from app module. -Remove `proguard-rules.pro` from network module. - Move `proguard-rules.pro` to `core` module.
- Update Android Gradle Plugin (AGP) to `8.6.1`. - Update Kotlin version to `2.1.0`. - Update Compose BOM to `2025.01.01`. - Update Compose Compiler to `1.5.1`. - Update Activity Compose to `1.10.0`. - Update Material Icons Extended Android to `1.7.7`. - Update Navigation Compose to `2.8.6`. - Update Room Compiler, Runtime, and KTX to `2.6.1` - Update `kotlinx.serialization.json` to `1.5.0`. - Update `kotlinx-coroutines-test` to `1.9.0`. - Update `retrofit` to `2.11.0`. - Update `androidx.datastore-core-android` to `1.1.2`. - Update `dagger` and `dagger-compiler` to `2.55`. - Add `androidx-hilt-navigation-compose` library. - Add `androidx.compose.runtime` and set version to `1.7.7` - Add `jetbrains-kotlin-jvm` plugin and set version to `1.9.24`. - Add `kotlinx-coroutines-core` library with version `1.9.0`. - Add `androidx-datastore-preferences` library. - Add `engageCore` library with version `1.5.6` - Introduce `feature-convention` and `sources-convention` plugins. - Rename `com.android.convention.library` to `com.android.library` - Configure Kotlin JVM target to `JVM_17` in `KotlinCompile`. - Add `utilities.kt` to include the `libs` shortcut. - Set the default application ID to `com.samuelokello.shopspot`. - Set `minSdk` version to `25`. - Add `dagger` dependency to `libs.versions.toml` - Update the versions and names of plugins to `com-android-application`, `org-jetbrains-kotlin-android`, `com-android-library`, `org.jetbrains.kotlin.jvm` and `org.jetbrains.kotlin.plugin.compose`. - Add `implementation` dependencies for `dagger-hilt` , `dagger-hilt-compiler` and `androidx-hilt-navigation-compose` in `AndroidHiltConventionPlugin` - Enable `allWarningsAsErrors` in `configureKotlin` using `compilerOptions` - Update `configureAndroidCompose` to use `compilerOptions` instead of `kotlinOptions` - Refactor `buildComposeMetricsParameters` in `configureAndroidCompose` to make it use the `project.layout.buildDirectory`
- add common ui composables
- separate network and local data sources - implement repository interfaces
- implement search screen - implement search logic for retrieving products from the local db(room).
- implement search screen - implement search logic for retrieving products from the local db(room).
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.