Skip to content
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

Initial Draft Version of Application #4

Merged
merged 44 commits into from
Sep 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
176c7ae
[INIT] Add gitignore
doyoonkim3312 Sep 22, 2024
e052312
[INIT] Restore files from previous repository
doyoonkim3312 Sep 22, 2024
57ef5c0
gitignore
doyoonkim3312 Sep 22, 2024
176a816
Merge pull request #1 from KNUTICE/main
doyoonkim3312 Sep 22, 2024
1bd3936
Merge pull request #2 from KNUTICE/development
doyoonkim3312 Sep 22, 2024
a548df4
[FIX] Load API information from local location
doyoonkim3312 Sep 22, 2024
dcbd37e
[FEAT] Add Workflows
doyoonkim3312 Sep 22, 2024
1b3fbe2
[FIX] Add sensitive data through Repository Secrets
doyoonkim3312 Sep 23, 2024
5d96ab9
[FIX] Add sensitive data through Repository Secrets
doyoonkim3312 Sep 23, 2024
76ab1d7
[CHORE] Add Missing permission
doyoonkim3312 Sep 23, 2024
a9fa16d
[FEAT] Add Necessary Library
doyoonkim3312 Sep 23, 2024
f1d5de7
[FEAT] Initial draft of Main Service Page.
doyoonkim3312 Sep 23, 2024
adb58d4
[FEAT] Feature 'Fetch Top Three Notices by categories'
doyoonkim3312 Sep 23, 2024
9872bfd
[FIX] Add missing Tag
doyoonkim3312 Sep 23, 2024
6b52339
[ETC] Configuration file updated.
doyoonkim3312 Sep 23, 2024
70dfe97
[FEAT] Apply Local-level layer for processing data.
doyoonkim3312 Sep 24, 2024
9890c96
[REFATOR] Apply local repository with improved pipeline
doyoonkim3312 Sep 24, 2024
c564d15
[FEAT] Add interface for UseCase
doyoonkim3312 Sep 24, 2024
10ac482
[REFACTOR] Replace Outdated Function
doyoonkim3312 Sep 24, 2024
5e96f25
[CHORE] Add new string resource
doyoonkim3312 Sep 25, 2024
9688322
[FEAT] Add Dummy Data Generator
doyoonkim3312 Sep 25, 2024
eb1662f
[REFACTOR] Apply Dummy Data generator.
doyoonkim3312 Sep 25, 2024
2f7768d
[FEAT] Add placeholder Shimmer effect
doyoonkim3312 Sep 25, 2024
3f74d65
[CHORE] Remove unnecessary import statement
doyoonkim3312 Sep 25, 2024
14b96ce
[CHORE] Implement necessary libraries
doyoonkim3312 Sep 30, 2024
4b0ad76
[FEAT] Add Required Vector Asset
doyoonkim3312 Sep 30, 2024
2fab5c3
[FEAT] Apply Compose Navigator
doyoonkim3312 Sep 30, 2024
441c1a9
[REFACTOR] Modify CategorizedNotificationViewModel
doyoonkim3312 Sep 30, 2024
4fc2ebd
[REFACTOR] Merge all data classes into one file.
doyoonkim3312 Sep 30, 2024
5a29a15
[FEAT] Interface for new behavior
doyoonkim3312 Sep 30, 2024
22ef140
[FEAT] New Use Case: FetchNoticePerPageInCategory
doyoonkim3312 Sep 30, 2024
ae6c00a
[CHORE] Revert function parameter
doyoonkim3312 Sep 30, 2024
412f23d
[ETC] Automatic Configuration Update.
doyoonkim3312 Sep 30, 2024
2757591
[FEAT] Apply Compose Navigator
doyoonkim3312 Sep 30, 2024
bd825aa
[FEAT] Create new ViewModel: MainActivityViewModel
doyoonkim3312 Sep 30, 2024
c9b43f2
[FEAT] Main Navigator.
doyoonkim3312 Sep 30, 2024
f9cfdce
[FEAT] MoreCategorizedNotification
doyoonkim3312 Sep 30, 2024
6f97617
[FEAT] Add new ViewModel: MoreCategorizedNotificationViewModel
doyoonkim3312 Sep 30, 2024
170ac30
[ETC] Class for creating dummy data.
doyoonkim3312 Sep 30, 2024
d713412
[FEAT] Add new function for initiating necessary data receiving over …
doyoonkim3312 Sep 30, 2024
7f37fad
[FEAT] Add new behavior under Retrofit service
doyoonkim3312 Sep 30, 2024
fed258a
[REFACTOR] Separate Reusable Composable into Its Own File.
doyoonkim3312 Sep 30, 2024
e4256c5
[REFACTOR] Separate Custom Types into a Single File.
doyoonkim3312 Sep 30, 2024
f410948
Merge pull request #3 from KNUTICE/development
doyoonkim3312 Sep 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions .github/workflows/GenerateBuildArtifact.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Generate Build Artifact

on:
pull_request:
branches: ["main", "release"]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]

- name: Setup Java JDk
uses: actions/[email protected]
with:
java-version: '17'
distribution: 'adopt'

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

- name: Decode BASEURL
env:
BASEURL: ${{ secrets.BASEURL }}
run: echo BASEURL="$BASEURL" > ./local.properties

- name: Clean Project
run: ./gradlew clean

- name: Build with Gradle
run: ./gradlew

- name: Generate and upload a Build Artifact
uses: actions/[email protected]
with:
name: KNUTICE_RC.apk
path: app/build/outputs/apk/debug/app-debug.apk
32 changes: 32 additions & 0 deletions .github/workflows/ValidateDevelopmentForRelease.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Validate Development for Release

on:
push:
branches: ["development"]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]

- name: Setup Java JDk
uses: actions/[email protected]
with:
java-version: '17'
distribution: 'adopt'

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

- name: Decode BASEURL
env:
BASEURL: ${{ secrets.BASEURL }}
run: echo BASEURL="$BASEURL" > ./local.properties

- name: Clean Project
run: ./gradlew clean

- name: Build with Gradle
run: ./gradlew build
33 changes: 33 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Gradle files
.gradle/
build/

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

# Log/OS Files
*.log

# Android Studio generated files and folders
captures/
.externalNativeBuild/
.cxx/
*.apk
output.json

# IntelliJ
*.iml
.idea/
misc.xml
deploymentTargetDropDown.xml
render.experimental.xml

# Keystore files
*.jks
*.keystore

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

# Android Profiling
*.hprof
33 changes: 33 additions & 0 deletions app/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Gradle files
.gradle/
build/

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

# Log/OS Files
*.log

# Android Studio generated files and folders
captures/
.externalNativeBuild/
.cxx/
*.apk
output.json

# IntelliJ
*.iml
.idea/
misc.xml
deploymentTargetDropDown.xml
render.experimental.xml

# Keystore files
*.jks
*.keystore

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

# Android Profiling
*.hprof
108 changes: 108 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
import java.io.FileInputStream
import java.util.Properties

plugins {
alias(libs.plugins.android.application)
alias(libs.plugins.kotlin.android)

// Dagger-Hilt for Dependency Injection
id("kotlin-kapt")
id("com.google.dagger.hilt.android")
}

android {
namespace = "com.example.knutice"
compileSdk = 34

val properties = Properties().apply {
load(FileInputStream("${rootDir}/local.properties"))
}
val apiRoot = properties["api_root"] ?: ""

defaultConfig {
applicationId = "com.example.knutice"
minSdk = 29
targetSdk = 34
versionCode = 1
versionName = "1.0"

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
useSupportLibrary = true
}

buildConfigField("String", "API_ROOT", "\"$apiRoot\"")
}

buildTypes {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
buildFeatures {
compose = true
buildConfig = true
}
composeOptions {
kotlinCompilerExtensionVersion = "1.5.1"
}
packaging {
resources {
excludes += "/META-INF/{AL2.0,LGPL2.1}"
}
}
}

dependencies {

implementation(libs.androidx.core.ktx)
implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.activity.compose)
implementation(platform(libs.androidx.compose.bom))
implementation(libs.androidx.ui)
implementation(libs.androidx.ui.graphics)
implementation(libs.androidx.ui.tooling.preview)
implementation(libs.androidx.material3)
implementation(libs.androidx.material)
testImplementation(libs.junit)
testImplementation(libs.kotlinx.coroutines.test) // Library to test coroutines in JUnit
androidTestImplementation(libs.androidx.junit)
androidTestImplementation(libs.androidx.espresso.core)
androidTestImplementation(platform(libs.androidx.compose.bom))
androidTestImplementation(libs.androidx.ui.test.junit4)
debugImplementation(libs.androidx.ui.tooling)
debugImplementation(libs.androidx.ui.test.manifest)

// Coroutine for Android
implementation(libs.kotlinx.coroutines.android)
// Navigation for Compose
implementation(libs.androidx.navigation.compose)
// Coil
implementation(libs.coil.compose)

// Dagger Hilt for Dependency Injection
implementation(libs.hilt.android)
implementation(libs.androidx.hilt.navigation.compose) // With Compose Navigation
kapt(libs.hilt.android.compiler)

// Retrofit 2
implementation(libs.retrofit)
implementation(libs.converter.gson)

}

// Allow references to generated code
kapt {
correctErrorTypes = true
}
21 changes: 21 additions & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html

# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}

# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable

# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package com.doyoonkim.knutice

import androidx.test.platform.app.InstrumentationRegistry
import androidx.test.ext.junit.runners.AndroidJUnit4

import org.junit.Test
import org.junit.runner.RunWith

import org.junit.Assert.*

/**
* Instrumented test, which will execute on an Android device.
*
* See [testing documentation](http://d.android.com/tools/testing).
*/
@RunWith(AndroidJUnit4::class)
class ExampleInstrumentedTest {
@Test
fun useAppContext() {
// Context of the app under test.
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
assertEquals("com.example.knutice", appContext.packageName)
}
}
31 changes: 31 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">

<uses-permission android:name="android.permission.INTERNET" />

<application
android:name="com.doyoonkim.knutice.MainApplication"
android:allowBackup="true"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/Theme.KNUTICE"
tools:targetApi="31">
<activity
android:name="com.doyoonkim.knutice.presentation.MainActivity"
android:exported="true"
android:label="@string/app_name"
android:theme="@style/Theme.KNUTICE">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>

</manifest>
16 changes: 16 additions & 0 deletions app/src/main/java/com/doyoonkim/knutice/MainApplication.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package com.doyoonkim.knutice

import android.app.Application
import dagger.hilt.android.HiltAndroidApp

@HiltAndroidApp
class MainApplication : Application() {

override fun onCreate() {
super.onCreate()
}

override fun onTerminate() {
super.onTerminate()
}
}
Loading
Loading