-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: Implement Log module * chore: Change OSLog to
- Loading branch information
Showing
7 changed files
with
51 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,6 @@ | |
// | ||
|
||
import DesignSystem | ||
import OSLog | ||
import UIKit | ||
|
||
// MARK: - WorkoutEnvironmentSetupViewController | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import ProjectDescription | ||
import ProjectDescriptionHelpers | ||
|
||
let project = Project.makeModule( | ||
name: "Log", | ||
targets: .custom(name: "Log", product: .framework) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
// | ||
// Log.swift | ||
// DesignSystem | ||
// | ||
// Created by 홍승현 on 11/23/23. | ||
// Copyright © 2023 kr.codesquad.boostcamp8. All rights reserved. | ||
// | ||
|
||
import OSLog | ||
|
||
/// 로그 | ||
public enum Log { | ||
|
||
/// Logger를 생성합니다. | ||
/// - Parameter category: Log를 구분하는 Category | ||
public static func make(with category: LogCategory = .default) -> Logger { | ||
return Logger(subsystem: .bundleIdentifier, category: category.rawValue) | ||
} | ||
} | ||
|
||
|
||
/// 로그 카테고리 | ||
public enum LogCategory: String { | ||
|
||
/// 기본값으로 들어갑니다. | ||
case `default` | ||
|
||
/// UI 로그를 작성할 때 사용합니다. | ||
case userInterface | ||
|
||
/// 네트워크 로그를 작성할 때 사용합니다. | ||
case network | ||
} | ||
|
||
|
||
private extension String { | ||
static let bundleIdentifier: String = Bundle.main.bundleIdentifier ?? "None" | ||
} |
This file was deleted.
Oops, something went wrong.