Skip to content

Commit

Permalink
1.0.0-beta01
Browse files Browse the repository at this point in the history
feat: app - Calendar
feat: app - Login/Logout
feat: app - Online/Offline Sync Memo
feat: server - Login/Logout
feat: server - Upsert/Fetch Memo
feat: server - Migrate Memo
  • Loading branch information
taetae98coding committed Nov 8, 2024
0 parents commit 8d16687
Show file tree
Hide file tree
Showing 607 changed files with 24,267 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
root = true

[{*.kt,*.kts}]
max_line_length = 300
insert_final_newline = true
trim_trailing_whitespace = true

ij_kotlin_imports_layout = unset
ij_kotlin_allow_trailing_comma = true
ij_kotlin_allow_trailing_comma_on_call_site = true

ktlint_experimental = disabled
ktlint_standard_function-signature = disabled
10 changes: 10 additions & 0 deletions .github/actions/ci-setup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
name: CI setup

runs:
using: composite
steps:
- name: Setup Java 17
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
65 changes: 65 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: Build

on: [ push, pull_request ]

jobs:
Linux-Build:
runs-on: ubuntu-latest
strategy:
matrix:
command: [
'./gradlew :app:platform:jvm:assemble',
'./gradlew :app:platform:wasm:assemble',
'./gradlew :app:platform:android:assembleRealRelease',
]
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- name: Build ${{ matrix.command }}
run: ${{ matrix.command }}

Mac-Build:
runs-on: macos-15
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- name: Build iOS
run: xcodebuild -project Diary/Diary.xcodeproj -scheme CI -destination 'platform=iOS Simulator,name=iPhone 16,OS=18.0'
30 changes: 30 additions & 0 deletions .github/workflows/check_code_style.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Check Code Style

on: [ push, pull_request ]

jobs:
Spotless:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- run: ./gradlew :spotlessCheck
37 changes: 37 additions & 0 deletions .github/workflows/dependency_guard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Dependency Guard

on: [ push, pull_request ]

jobs:
Dependency-Guard:
runs-on: ubuntu-latest
strategy:
matrix:
command: [
'./gradlew :app:platform:android:dependencyGuard',
'./gradlew :server:app:dependencyGuard'
]
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- name: Build ${{ matrix.command }}
run: ${{ matrix.command }}
154 changes: 154 additions & 0 deletions .github/workflows/firebase_app_distribution.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
name: Firebase App Distribution

on:
push:
branches:
- main
workflow_dispatch:

jobs:
Android-Distribution:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- name: Build APK
run: ./gradlew :app:platform:android:assembleRealRelease

- name: Distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1
with:
appId: ${{ secrets.FIREBASE_ANDROID_REAL_RELEASE_APP_ID }}
serviceCredentialsFileContent: ${{ secrets.FIREBASE_APP_DISTRIBUTION_KEY }}
groups: Developer,Android
file: app/platform/android/build/outputs/apk/real/release/android-real-release.apk
releaseNotesFile: CHANGELOG.md

iOS-Build:
runs-on: macos-15
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- name: Install the Apple certificate and provisioning profile
env:
BUILD_CERTIFICATE_BASE64: ${{ secrets.APPLE_DISTRIBUTION_CERTIFICATE }}
P12_PASSWORD: ${{ secrets.APPLE_DISTRIBUTION_CERTIFICATE_PASSWORD }}
BUILD_PROVISION_PROFILE_BASE64: ${{ secrets.APPLE_DISTRIBUTION_PROFILE }}
KEYCHAIN_PASSWORD: ${{ secrets.APPLE_DISTRIBUTION_TEMPORARY_KEYCHAIN_PASSWORD }}
run: |
# create variables
CERTIFICATE_PATH=$RUNNER_TEMP/build_certificate.p12
PP_PATH=$RUNNER_TEMP/build_pp.mobileprovision
KEYCHAIN_PATH=$RUNNER_TEMP/app-signing.keychain-db
# import certificate and provisioning profile from secrets
echo -n "$BUILD_CERTIFICATE_BASE64" | base64 --decode -o $CERTIFICATE_PATH
echo -n "$BUILD_PROVISION_PROFILE_BASE64" | base64 --decode -o $PP_PATH
# create temporary keychain
security create-keychain -p "$KEYCHAIN_PASSWORD" $KEYCHAIN_PATH
security set-keychain-settings -lut 21600 $KEYCHAIN_PATH
security unlock-keychain -p "$KEYCHAIN_PASSWORD" $KEYCHAIN_PATH
# import certificate to keychain
security import $CERTIFICATE_PATH -P "$P12_PASSWORD" -A -t cert -f pkcs12 -k $KEYCHAIN_PATH
security set-key-partition-list -S apple-tool:,apple: -k "$KEYCHAIN_PASSWORD" $KEYCHAIN_PATH
security list-keychain -d user -s $KEYCHAIN_PATH
# apply provisioning profile
mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles
cp $PP_PATH ~/Library/MobileDevice/Provisioning\ Profiles
- name: Archive xcarchive
run: xcodebuild -project Diary/Diary.xcodeproj -scheme CI archive -archivePath Diary/build/Diary.xcarchive -allowProvisioningUpdates

- name: Export ipa
run: xcodebuild -exportArchive -archivePath Diary/build/Diary.xcarchive -exportPath Diary/build -exportOptionsPlist Diary/ExportOptions.plist -allowProvisioningUpdates

- name: Upload ipa
uses: actions/upload-artifact@v4
with:
name: Diary.ipa
path: Diary/build/Apps/Diary.ipa

iOS-Distribution:
needs: [iOS-Build]
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: CI setup
uses: './.github/actions/ci-setup'

- name: Set local.properties
run: |
echo diary.dev.api.base.url=${{ secrets.DIARY_DEV_API_BASE_URL }} >> local.properties
echo diary.real.api.base.url=${{ secrets.DIARY_REAL_API_BASE_URL }} >> local.properties
echo holiday.dev.api.url=${{ secrets.HOLIDAY_DEV_API_URL }} >> local.properties
echo holiday.dev.api.key=${{ secrets.HOLIDAY_DEV_API_KEY }} >> local.properties
echo holiday.real.api.url=${{ secrets.HOLIDAY_REAL_API_URL }} >> local.properties
echo holiday.real.api.key=${{ secrets.HOLIDAY_REAL_API_KEY }} >> local.properties
echo android.dev.store.password=${{ secrets.ANDROID_DEV_STORE_PASSWORD }} >> local.properties
echo android.dev.key.alias=${{ secrets.ANDROID_DEV_KEY_ALIAS }} >> local.properties
echo android.dev.key.password=${{ secrets.ANDROID_DEV_KEY_PASSWORD }} >> local.properties
echo android.real.store.password=${{ secrets.ANDROID_REAL_STORE_PASSWORD }} >> local.properties
echo android.real.key.alias=${{ secrets.ANDROID_REAL_KEY_ALIAS }} >> local.properties
echo android.real.key.password=${{ secrets.ANDROID_REAL_KEY_PASSWORD }} >> local.properties
- name: Download ipa
uses: actions/download-artifact@v4
with:
name: Diary.ipa

- name: Distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1
with:
appId: ${{ secrets.FIREBASE_IOS_REAL_RELEASE_APP_ID }}
serviceCredentialsFileContent: ${{ secrets.FIREBASE_APP_DISTRIBUTION_KEY }}
groups: Developer,iOS
file: Diary.ipa
releaseNotesFile: CHANGELOG.md

- name: Delete temp ipa
uses: geekyeggo/delete-artifact@v5
with:
name: Diary.ipa
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
**/.gradle
**/.idea
**/.kotlin

**/local.properties

**/build

**/xcuserdata
**/dev.xcconfig
**/real.xcconfig
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Diary Changelog

All notable changes to this project will be documented in this file.

## [1.0.0-beta01] - 2024-11-06

### 🚀 Features

- App - Calendar
- App - Login/Logout
- App - Online/Offline Sync Memo
- Server - Login/Logout
- Server - Upsert/Fetch Memo
- Server - Migrate Memo

<!-- generated by git-cliff -->
Loading

0 comments on commit 8d16687

Please sign in to comment.