Skip to content

Commit e5be2c3

Browse files
authored
Merge pull request #29 from KryptKode/chore/update-readme
chore: update README.md, manage deps
2 parents 6731688 + b82b68e commit e5be2c3

File tree

2 files changed

+103
-5
lines changed

2 files changed

+103
-5
lines changed

README.md

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,102 @@
11
# Farmz
22
A simple android application to fetch, update farmers and register their farms
3+
Fully compatible with [Android 11][android-q], supporting light and [dark theme][dark-theme] (see screenshots)
4+
5+
## API Key
6+
The app uses google maps to display location of farms. Get an api key [here](https://developers.google.com/maps/documentation/android-sdk/get-api-key) <br/>
7+
8+
* Create the file `secure.properties` in your project level directory, and then add the following code to the file. Replace `YOUR_API_KEY` with your API key.
9+
```
10+
MAPS_API_KEY=YOUR_API_KEY
11+
12+
```
13+
14+
* Place it in `app/build.gradle`
15+
```
16+
android {
17+
defaultConfig {
18+
...
19+
def secureProps = new Properties()
20+
if (file("../secure.properties").exists()) {
21+
file("../secure.properties")?.withInputStream { secureProps.load(it) }
22+
}
23+
resValue "string", "maps_api_key", (secureProps.getProperty("MAPS_API_KEY") ?: "")
24+
...
25+
}
26+
...
27+
}
28+
```
29+
30+
## Download APK
31+
You can download the APK from [releases](https://play.google.com/store/apps/details?id=com.momentolabs.app.security.applocker&hl=en) <br/>
32+
Use email `a@b.c` and password `123456` to log in
33+
34+
35+
## What you can learn
36+
* [Material Components][material]
37+
* [Constraint Layout][constraint-layout]
38+
* [Retrofit][retrofit] for REST api communication
39+
* [Glide][glide] for image loading
40+
* [Mockk][mockk] for mocking in tests
41+
* [Dagger2][dagger2] for dependency injection
42+
* [Room][room] for database
43+
* [Kotlin Flow][flow] for concurrency
44+
* [ViewModel][viewmodel] & [LiveData][livedata]
45+
* [Navigation Architecture Component][nav]
46+
* [Clean Architecture][clean-arch]
47+
* [ViewBinding][viewbinding]
48+
* [Kotlin Delegates][delegates]
49+
* [DataStore][datastore]
50+
* [Paging 3.0][paging-3]
51+
* [Google Maps][maps]
52+
* [Activity Results API][results]
53+
54+
55+
56+
57+
[mockwebserver]: https://github.com/square/okhttp/tree/master/mockwebserver
58+
[androidx]: https://developer.android.com/jetpack/androidx
59+
[arch]: https://developer.android.com/arch
60+
[espresso]: https://google.github.io/android-testing-support-library/docs/espresso/
61+
[retrofit]: http://square.github.io/retrofit
62+
[glide]: https://github.com/bumptech/glide
63+
[mockk]: https://github.com/mockk/mockk
64+
[dagger2]: https://github.com/google/dagger
65+
[kotlin]: https://developer.android.com/kotlin
66+
[material]: https://github.com/material-components/material-components-android/
67+
[android-q]: https://developer.android.com/preview
68+
[dark-theme]: https://developer.android.com/preview/features/darktheme
69+
[constraint-layout]: https://developer.android.com/reference/android/support/constraint/ConstraintLayout
70+
[rxjava2]: https://github.com/ReactiveX/RxJava
71+
[room]: https://developer.android.com/topic/libraries/architecture/room
72+
[paging-3]:https://developer.android.com/topic/libraries/architecture/paging/v3-overview
73+
[maps]:https://developers.google.com/maps/documentation/android-sdk/overview
74+
[livedata]:https://developer.android.com/topic/libraries/architecture/livedata
75+
[viewmodel]:https://developer.android.com/topic/libraries/architecture/viewmodel
76+
[datastore]:https://developer.android.com/topic/libraries/architecture/datastore
77+
[flow]:https://kotlinlang.org/docs/reference/coroutines/flow.html
78+
[clean-arch]:https://blog.cleancoder.com/uncle-bob/2012/08/13/the-clean-architecture.html
79+
[nav]:https://developer.android.com/guide/navigation/navigation-getting-started
80+
[viewbinding]:https://developer.android.com/topic/libraries/view-binding
81+
[delegates]:https://kotlinlang.org/docs/reference/delegated-properties.html
82+
[results]:https://developer.android.com/training/basics/intents/result
83+
84+
85+
## Possible Improvements
86+
- Add logout funtionality
87+
- Change theme
88+
- Improve pagination
89+
- Use multiple back stacks on bottom navigation
90+
- Improve UI/UX
91+
92+
93+
## Screenshots
94+
### Dark
95+
<img src="https://user-images.githubusercontent.com/25648077/96524630-b4917200-1270-11eb-8d97-68abf65d5619.gif" width="302" alt="Screenshot">
96+
97+
### Light
98+
<img src="https://user-images.githubusercontent.com/25648077/96524147-5fa12c00-126f-11eb-9cc0-803126c99647.gif" width="302" alt="Screenshot">
99+
100+
101+
### Lines of code
102+
<img src="https://user-images.githubusercontent.com/25648077/96524965-911af700-1271-11eb-8bbf-ea788f53f1ba.png" alt="Lines of code">

app/build.gradle

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -118,12 +118,10 @@ dependencies {
118118

119119
implementation "androidx.multidex:multidex:2.0.1"
120120

121-
implementation "com.jakewharton.timber:timber:4.7.1"
122-
123-
def permissionsDispatcherVersion = "4.7.0"
124-
implementation "org.permissionsdispatcher:permissionsdispatcher:${permissionsDispatcherVersion}"
125-
kapt "org.permissionsdispatcher:permissionsdispatcher-processor:${permissionsDispatcherVersion}"
121+
implementation "androidx.activity:activity-ktx:1.2.0-beta01"
122+
implementation "androidx.fragment:fragment-ktx:1.3.0-beta01"
126123

124+
implementation "com.jakewharton.timber:timber:4.7.1"
127125

128126
def daggerVersion = "2.27"
129127
implementation "com.google.dagger:dagger-android:$daggerVersion"

0 commit comments

Comments
 (0)