Skip to content

Commit

Permalink
Merge pull request #451 from wakmusic/417-once-run-swift-format
Browse files Browse the repository at this point in the history
๐Ÿ”€ :: (#417) SwiftFormat ํ•œ ๋ฒˆ ๋Œ๋ฆฌ๊ธฐ
  • Loading branch information
baekteun authored Mar 9, 2024
2 parents 27fc658 + 904b9f5 commit 0d492df
Show file tree
Hide file tree
Showing 544 changed files with 10,062 additions and 8,916 deletions.
9 changes: 9 additions & 0 deletions .swiftlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ force_cast: # From https://realm.github.io/SwiftLint/force_cast.html
identifier_name:
min_length:
warning: 1
allowed_symbols: ["_"]

nesting:
type_label:
Expand All @@ -17,3 +18,11 @@ nesting:
type_name:
max_length:
warning: 60

function_body_length:
warning: 100
error: 300

function_parameter_count:
warning: 10
error: 15
71 changes: 35 additions & 36 deletions Projects/App/Project.swift
Original file line number Diff line number Diff line change
@@ -1,24 +1,23 @@
import ProjectDescriptionHelpers
import ProjectDescription
import EnvironmentPlugin
import Foundation
import ProjectDescription
import ProjectDescriptionHelpers

let settinges: Settings =
.settings(base: env.baseSetting,
configurations: [
.debug(name: .debug),
.release(name: .release)
],
defaultSettings: .recommended)

.settings(
base: env.baseSetting,
configurations: [
.debug(name: .debug),
.release(name: .release)
],
defaultSettings: .recommended
)

let isForDev = (ProcessInfo.processInfo.environment["TUIST_ENV"] ?? "DEV") == "DEV" ? true : false

let scripts: [TargetScript] = isForDev ? [.swiftLint, .needle] : [.firebaseCrashlytics]


let targets: [Target] = [

.init(
name: env.name,
platform: .iOS,
Expand Down Expand Up @@ -46,7 +45,7 @@ let targets: [Target] = [
]
)
),

.init(
name: "\(env.name)Tests",
platform: .iOS,
Expand All @@ -63,31 +62,31 @@ let targets: [Target] = [

let schemes: [Scheme] = [
.init(
name: "\(env.name)Tests-DEBUG",
shared: true,
buildAction: .buildAction(targets: ["\(env.name)"]),
testAction: TestAction.targets(
["\(env.name)"],
configuration: .debug,
options: TestActionOptions.options(
coverage: true,
codeCoverageTargets: ["\(env.name)"]
)
),
runAction: .runAction(configuration: .debug),
archiveAction: .archiveAction(configuration: .debug),
profileAction: .profileAction(configuration: .debug),
analyzeAction: .analyzeAction(configuration: .debug)
name: "\(env.name)Tests-DEBUG",
shared: true,
buildAction: .buildAction(targets: ["\(env.name)"]),
testAction: TestAction.targets(
["\(env.name)"],
configuration: .debug,
options: TestActionOptions.options(
coverage: true,
codeCoverageTargets: ["\(env.name)"]
)
),
runAction: .runAction(configuration: .debug),
archiveAction: .archiveAction(configuration: .debug),
profileAction: .profileAction(configuration: .debug),
analyzeAction: .analyzeAction(configuration: .debug)
),
.init(
name: "\(env.name)-RELEASE",
shared: true,
buildAction: BuildAction(targets: ["\(env.name)"]),
testAction: nil,
runAction: .runAction(configuration: .release),
archiveAction: .archiveAction(configuration: .release),
profileAction: .profileAction(configuration: .release),
analyzeAction: .analyzeAction(configuration: .release)
name: "\(env.name)-RELEASE",
shared: true,
buildAction: BuildAction(targets: ["\(env.name)"]),
testAction: nil,
runAction: .runAction(configuration: .release),
archiveAction: .archiveAction(configuration: .release),
profileAction: .profileAction(configuration: .release),
analyzeAction: .analyzeAction(configuration: .release)
)
]

Expand All @@ -96,7 +95,7 @@ let project: Project =
name: env.name,
organizationName: env.organizationName,
packages: [],
//packages: [.Amplify],
// packages: [.Amplify],
settings: settinges,
targets: targets,
schemes: schemes
Expand Down
8 changes: 5 additions & 3 deletions Projects/App/Sources/Application/AppComponent+App.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
// Copyright ยฉ 2023 yongbeomkwak. All rights reserved.
//

import DomainModule
import DataModule
import NetworkModule
import AppDomain
import AppDomainInterface
import DataModule
import DomainModule
import NetworkModule

// MARK: ๋ณ€์ˆ˜๋ช… ์ฃผ์˜
// AppComponent ๋‚ด ๋ณ€์ˆ˜ == Dependency ๋‚ด ๋ณ€์ˆ˜ ์ด๋ฆ„ ๊ฐ™์•„์•ผํ•จ
Expand All @@ -21,11 +21,13 @@ public extension AppComponent {
RemoteAppDataSourceImpl(keychain: keychain)
}
}

var appRepository: any AppRepository {
shared {
AppRepositoryImpl(remoteAppDataSource: remoteAppDataSource)
}
}

var fetchAppCheckUseCase: any FetchAppCheckUseCase {
shared {
FetchAppCheckUseCaseImpl(appRepository: appRepository)
Expand Down
22 changes: 11 additions & 11 deletions Projects/App/Sources/Application/AppComponent+Artist.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,51 +6,51 @@
// Copyright ยฉ 2023 yongbeomkwak. All rights reserved.
//

import ArtistFeature
import ArtistDomain
import ArtistDomainInterface
import ArtistFeature

public extension AppComponent {
//MARK: Artist
// MARK: Artist
var artistComponent: ArtistComponent {
ArtistComponent(parent: self)
}

var remoteArtistDataSource: RemoteArtistDataSourceImpl {
shared {
RemoteArtistDataSourceImpl(keychain: keychain)
}
}

var artistRepository: any ArtistRepository {
shared {
ArtistRepositoryImpl(remoteArtistDataSource: remoteArtistDataSource)
}
}

var fetchArtistListUseCase: any FetchArtistListUseCase {
shared {
FetchArtistListUseCaseImpl(artistRepository: artistRepository)
}
}
//MARK: Artist Detail

// MARK: Artist Detail
var artistDetailComponent: ArtistDetailComponent {
ArtistDetailComponent(parent: self)
}

var fetchArtistSongListUseCase: any FetchArtistSongListUseCase {
shared {
FetchArtistSongListUseCaseImpl(artistRepository: artistRepository)
}
}
//MARK: Artist Detail > Artist Music

// MARK: Artist Detail > Artist Music
var artistMusicComponent: ArtistMusicComponent {
ArtistMusicComponent(parent: self)
}

//MARK: Artist Detail > Artist Music > Artist Music Content
// MARK: Artist Detail > Artist Music > Artist Music Content
var artistMusicContentComponent: ArtistMusicContentComponent {
ArtistMusicContentComponent(parent: self)
}
Expand Down
34 changes: 11 additions & 23 deletions Projects/App/Sources/Application/AppComponent+Auth.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,66 +6,54 @@
// Copyright ยฉ 2023 yongbeomkwak. All rights reserved.
//

import DomainModule
import CommonFeature
import DataModule
import DomainModule
import NetworkModule
import CommonFeature
import SignInFeature
import StorageFeature

//MARK: ๋ณ€์ˆ˜๋ช… ์ฃผ์˜
// MARK: ๋ณ€์ˆ˜๋ช… ์ฃผ์˜
// AppComponent ๋‚ด ๋ณ€์ˆ˜ == Dependency ๋‚ด ๋ณ€์ˆ˜ ์ด๋ฆ„ ๊ฐ™์•„์•ผํ•จ


public extension AppComponent {

var signInComponent : SignInComponent {
var signInComponent: SignInComponent {
SignInComponent(parent: self)
}


var storageComponent : StorageComponent {

var storageComponent: StorageComponent {
StorageComponent(parent: self)

}

var afterLoginComponent: AfterLoginComponent {

AfterLoginComponent(parent: self)
}

var requestComponent: RequestComponent {
RequestComponent(parent: self)
}




var remoteAuthDataSource: any RemoteAuthDataSource {
shared {
RemoteAuthDataSourceImpl(keychain: keychain)
}
}

var authRepository: any AuthRepository {
shared {
AuthRepositoryImpl(remoteAuthDataSource: remoteAuthDataSource)
}
}



var fetchTokenUseCase: any FetchTokenUseCase {

shared {
FetchTokenUseCaseImpl(authRepository: authRepository)
}
}

var fetchNaverUserInfoUseCase: any FetchNaverUserInfoUseCase {

shared {
FetchNaverUserInfoUseCaseImpl(authRepository: authRepository)
}
}


}
7 changes: 3 additions & 4 deletions Projects/App/Sources/Application/AppComponent+Chart.swift
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import DomainModule
import DataModule
import NetworkModule
import ChartFeature
import CommonFeature
import DataModule
import DomainModule
import NetworkModule

public extension AppComponent {
var chartComponent: ChartComponent {
Expand Down Expand Up @@ -37,4 +37,3 @@ public extension AppComponent {
}
}
}

21 changes: 10 additions & 11 deletions Projects/App/Sources/Application/AppComponent+Faq.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,22 @@
// Copyright ยฉ 2023 yongbeomkwak. All rights reserved.
//

import DomainModule
import CommonFeature
import DataModule
import DomainModule
import NetworkModule
import CommonFeature
import SignInFeature
import StorageFeature

//MARK: ๋ณ€์ˆ˜๋ช… ์ฃผ์˜
// MARK: ๋ณ€์ˆ˜๋ช… ์ฃผ์˜
// AppComponent ๋‚ด ๋ณ€์ˆ˜ == Dependency ๋‚ด ๋ณ€์ˆ˜ ์ด๋ฆ„ ๊ฐ™์•„์•ผํ•จ


public extension AppComponent {
var faqComponent: FaqComponent {
var faqComponent: FaqComponent {
FaqComponent(parent: self)
}
var faqContentComponent: FaqContentComponent {

var faqContentComponent: FaqContentComponent {
FaqContentComponent(parent: self)
}

Expand All @@ -31,19 +30,19 @@ public extension AppComponent {
RemoteFaqDataSourceImpl(keychain: keychain)
}
}

var faqRepository: any FaqRepository {
shared {
FaqRepositoryImpl(remoteFaqDataSource: remoteFaqDataSource)
}
}
var fetchFaqCategoriesUseCase: any FetchFaqCategoriesUseCase{

var fetchFaqCategoriesUseCase: any FetchFaqCategoriesUseCase {
shared {
FetchFaqCategoriesUseCaseImpl(faqRepository: faqRepository)
}
}

var fetchFaqUseCase: any FetchFaqUseCase {
shared {
FetchFaqUseCaseImpl(faqRepository: faqRepository)
Expand Down
Loading

0 comments on commit 0d492df

Please sign in to comment.