Skip to content

Commit

Permalink
Merge pull request #147 from hellokitty-coding-club/feat/prepare-for-…
Browse files Browse the repository at this point in the history
…release

[RELEASE] v1.0.0 출시
  • Loading branch information
KxxHyoRim authored Oct 24, 2023
2 parents b94bc6b + 48e74cf commit 3aded45
Show file tree
Hide file tree
Showing 852 changed files with 17,606 additions and 217 deletions.
123 changes: 123 additions & 0 deletions .github/workflows/dependencyGraph.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
name: Generate Dependency Graph

on:
pull_request:
types:
- opened

jobs:
build:
name: PR Checker
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with :
persist-credentials: false
fetch-depth: 0

- name: Gradle cache
uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17

- name: Change gradlew permissions
run: chmod +x ./gradlew

- name: Touch lgtm properties
run: touch lgtm.properties

- name: Access LGTM_BASE_URL_DEBUG
env:
LGTM_BASE_URL_DEBUG: ${{ secrets.LGTM_BASE_URL_DEBUG }}
run: echo "LGTM_BASE_URL_DEBUG=\"$LGTM_BASE_URL_DEBUG\"" >> lgtm.properties

- name: Access LGTM_BASE_URL_RELEASE
env:
LGTM_BASE_URL_RELEASE: ${{ secrets.LGTM_BASE_URL_RELEASE }}
run: echo "LGTM_BASE_URL_RELEASE=\"$LGTM_BASE_URL_RELEASE\"" >> lgtm.properties

- name: Gradle cache
uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17

- name: Change gradlew permissions
run: chmod +x ./gradlew

- name: Touch lgtm properties
run: touch lgtm.properties

- name: Access LGTM_BASE_URL_DEBUG
env:
LGTM_BASE_URL_DEBUG: ${{ secrets.LGTM_BASE_URL_DEBUG }}
run: echo "LGTM_BASE_URL_DEBUG=\"$LGTM_BASE_URL_DEBUG\"" >> lgtm.properties

- name: Access LGTM_BASE_URL_RELEASE
env:
LGTM_BASE_URL_RELEASE: ${{ secrets.LGTM_BASE_URL_RELEASE }}
run: echo "LGTM_BASE_URL_RELEASE=\"$LGTM_BASE_URL_RELEASE\"" >> lgtm.properties

- name: Setup Graphviz
uses: ts-graphviz/setup-graphviz@v1

- name: Generate Dependency Graph
run: ./gradlew projectDependencyGraph --stacktrace

- name: Commit
run: |
git config --local user.email '[email protected]'
git config --local user.name 'GitHub Action'
git diff --quiet && git diff --staged --quiet || git commit -am '[DOCS] Update dependency graph'
- name: Push
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.TOKEN_GITHUB }}
branch: ${{ github.head_ref }}

- name: On Success!! Congratulations
if: ${{ success() }}
uses: rtCamp/action-slack-notify@v2
env:
SLACK_COLOR: '#53A551'
SLACK_ICON: https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/603efae5-02ba-4065-ba7b-ea36bc88acb6
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_TITLE: '[LGTM] Dependency graph is now up to date ✅'
MSG_MINIMAL: true
SLACK_USERNAME: LGTM-Android
SLACK_MESSAGE: 'Dependency graph has been updated to its latest state'

- name: On Failed, Notify in Slack
if: ${{ failure() }}
uses: rtCamp/action-slack-notify@v2
with:
status: ${{ job.status }}
env:
SLACK_COLOR: '#ff0000'
SLACK_ICON: https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/603efae5-02ba-4065-ba7b-ea36bc88acb6
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_TITLE: '[LGTM] Dependency graph update has failed ❌'
MSG_MINIMAL: ref,actions url,event,commit
SLACK_USERNAME: LGTM-Android
SLACK_MESSAGE: 'The attempt to update the dependency graph has encountered an issue'
35 changes: 31 additions & 4 deletions .github/workflows/prBuilder.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# This is a basic workflow to help you get started with Actions

name: LGTM PR Builder
name: LGTM PR Builder & App Distribution

on:
pull_request:
Expand All @@ -18,6 +16,9 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2
with :
persist-credentials: false
fetch-depth: 0

- name: Gradle cache
uses: actions/cache@v2
Expand All @@ -28,6 +29,7 @@ jobs:
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: set up JDK 17
uses: actions/setup-java@v1
with:
Expand All @@ -36,9 +38,34 @@ jobs:
- name: Change gradlew permissions
run: chmod +x ./gradlew

- name: Touch lgtm properties
run: touch lgtm.properties

- name: Access LGTM_BASE_URL_DEBUG
env:
LGTM_BASE_URL_DEBUG: ${{ secrets.LGTM_BASE_URL_DEBUG }}
run: echo "LGTM_BASE_URL_DEBUG=\"$LGTM_BASE_URL_DEBUG\"" >> lgtm.properties

- name: Access LGTM_BASE_URL_RELEASE
env:
LGTM_BASE_URL_RELEASE: ${{ secrets.LGTM_BASE_URL_RELEASE }}
run: echo "LGTM_BASE_URL_RELEASE=\"$LGTM_BASE_URL_RELEASE\"" >> lgtm.properties

- name: Build debug APK
run: ./gradlew assembleDebug --stacktrace

- name: Upload apk to Firebase App Distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1
with:
appId: ${{ secrets.FIREBASE_APP_ID }}
token: ${{ secrets.FIREBASE_TOKEN }}
groups: hello-kitty-coding-club
file: app/build/outputs/apk/debug/app-debug.apk
releaseNotes: |
${{ github.event.pull_request.title }}
${{ github.event.pull_request.html_url }}
${{ github.event.pull_request.body }}
- name: On Success!! Congratulations
if: ${{ success() }}
uses: rtCamp/action-slack-notify@v2
Expand All @@ -49,7 +76,7 @@ jobs:
SLACK_TITLE: '[LGTM] PR Check SUCCESS ✅'
MSG_MINIMAL: true
SLACK_USERNAME: LGTM-Android
SLACK_MESSAGE: 'PR이 완료되었습니다!!! 🎉🎉🎉'
SLACK_MESSAGE: 'Build and App distribution Success🎉🎉🎉'

- name: On Failed, Notify in Slack
if: ${{ failure() }}
Expand Down
11 changes: 10 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
# Created by https://www.toptal.com/developers/gitignore/api/android,androidstudio,kotlin
# Edit at https://www.toptal.com/developers/gitignore?templates=android,androidstudio,kotlin



### Android ###
# Gradle files
.gradle/
build/

# Local configuration file (sdk path, etc)
local.properties
lgtm.properties

# Log/OS Files
*.log
Expand All @@ -18,6 +21,7 @@ captures/
.cxx/
*.apk
output.json
app/release/output-metadata.json

# IntelliJ
*.iml
Expand All @@ -29,9 +33,11 @@ render.experimental.xml
# Keystore files
*.jks
*.keystore
private_key.pepk
LgtmKeyStore

# Google Services (e.g. APIs or Firebase)
google-services.json
# google-services.json

# Android Profiling
*.hprof
Expand Down Expand Up @@ -199,3 +205,6 @@ fabric.properties
/captures
.cxx

/app/release/output-metadata.json
/LgtmKeyStore
/private_key.pepk
71 changes: 71 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# 미션 기반 코드리뷰 매칭 플랫폼, LGTM

**'LGTM'은 SW 마에스트로 14기 프로젝트입니다.**

해당 `LGTM-Android` Repository는 **[@kxxhyorim](https://github.com/KxxHyoRim)** 1인 개발로 이루어지고 있습니다. (팀 구성 = 백엔드 2명, 안드로이드 1명)

![image](https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/4cff9177-ac15-4ddf-9a74-3a0654c8a502)




## ⚒️ Tech Stack

| Category | Details |
| ------------------- | -------------------------------------------- |
| Architecture | MVVM, Multi Module, Clean Architecture, Hilt |
| AAC | Databinding, Livedata, ViewModel, Navigation |
| Concurrency | Coroutine |
| Third Party Library | OkHttp3, Retrofit2, Glide |
| CI/CD | Github Actions |
| Language | Kotlin(100%) |



## ⛏️ Multi Module Architecutre

<img src="gradle/dependency-graph/project.dot.png" />


## ⛏️ Clean Architecutre

![image](https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/164234cb-32e1-4d6b-91d0-a2e9e3801128)



## 🖌️ Server Drivne UI

- **Home 화면의 경우, 앱 배포 없이 UI를 변경할 수 있는 `Server Driven UI`를 활용했습니다.**

- **도입 이유**

- 안드로이드 앱은 유저의 앱 업데이트를 강제하기 어려워서 유연한 변경사항 제공이 어렵다.
- 새로운 기능 & 수정사항을 모두에게 빠르게 반영하지 못한다.
- 클라이언트 코드 변경 없이 UI를 조정가능.

- **개괄적인 방식**

1. 클라이언트-백엔드 ViewType 정의 및 Json 설계

2. 서버가 API 응답에 UI 정보를 담아 클라이언트에 제공

3. 안드로이드에서는 동적으로 ViewType을 보고 홈화면의 UI 구성

- **Response 설계**

![image](https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/e1e12a75-9580-46c7-a981-423f1a0da17f)

- **안드로이드 구현**

![image](https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/7d360f52-3aee-4b56-8be2-45fa6ae879be)

## 🖼️ 구현 화면

| 화면 분류 | 이미지 |
| ------------------ | ------------------------------------------------------------ |
| 로그인 / 회원가입 | <img width=600 src="https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/65caad40-0866-499a-90e4-80ef942c38c2"/> |
| 홈화면 | <img width=600 src="https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/94a1cbc2-66fd-48df-8d4f-3cb03729f86c"/> |
| 미션 조회 (리뷰어) | <img width =600 src="https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/d2fee2fb-5559-454b-a3b3-787874cd4478"/> |
| 미션 조회 (리뷰이) | <img width=600 src="https://github.com/hellokitty-coding-club/LGTM-Android/assets/59546818/33cccfdd-c43c-4faf-8d5e-87b3dcdae316"/> |


39 changes: 34 additions & 5 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
import org.jetbrains.kotlin.konan.properties.Properties

val lgtmPropertiesFile = rootProject.file("lgtm.properties")
val lgtmProperties = Properties()
lgtmProperties.load(lgtmPropertiesFile.inputStream())

plugins {
kotlin("android")
id("com.android.application")
id("dagger.hilt.android.plugin")
id("com.google.gms.google-services")
id("com.google.firebase.crashlytics")
kotlin("kapt")
}

Expand All @@ -12,11 +20,24 @@ android {
applicationId = "com.lgtm.android"
versionCode = libs.versions.versionCode.get().toInt()
versionName = libs.versions.appVersion.get()
targetSdk = libs.versions.targetSdk.get().toInt()
vectorDrawables.useSupportLibrary = true

buildConfigField(
"String",
"LGTM_BASE_URL_DEBUG",
lgtmProperties.getProperty("LGTM_BASE_URL_DEBUG")
)
buildConfigField(
"String",
"LGTM_BASE_URL_RELEASE",
lgtmProperties.getProperty("LGTM_BASE_URL_RELEASE")
)
}
buildTypes {
release {
isMinifyEnabled = true
isShrinkResources = true
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
Expand All @@ -25,9 +46,12 @@ android {
}

buildFeatures {
dataBinding = true
buildConfig = true
}

lint {
disable += "Instantiatable"
}
}

kapt {
Expand All @@ -38,13 +62,18 @@ dependencies {
implementation(project(":domain"))
implementation(project(":data"))
implementation(project(":feature:auth"))
implementation(project(":feature:main"))
implementation(project(":feature:create_mission"))
implementation(project(":feature:mission_detail"))
implementation(project(":feature:manage_mission"))
implementation(project(":feature:profile"))
implementation(project(":common-ui"))

// todo) MainActivity Feature 모듈로 옮기고 나면 삭제
implementation(libs.bundles.androidx.ui.foundation)
implementation(libs.constraintlayout)

implementation(libs.hilt)
implementation(platform(libs.firebase))
implementation(libs.bundles.firebase)
kapt(libs.hilt.kapt)
implementation(libs.bundles.basic.test)
implementation(libs.security.cripto)

}
Loading

0 comments on commit 3aded45

Please sign in to comment.