Skip to content

Commit 3757207

Browse files
authored
Merge pull request #9 from VishwaiOSDev/feature/vishwa/new-logger-kit
Configured new LoggerKit and NetworkKit
2 parents e892b53 + a30ea5a commit 3757207

File tree

4 files changed

+35
-5
lines changed

4 files changed

+35
-5
lines changed

Loadify.xcodeproj/project.pbxproj

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
883233872855F34000BF38B5 /* Double+Extension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 883233862855F34000BF38B5 /* Double+Extension.swift */; };
1717
88379936283A19F400DDBA79 /* Int+Extension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88379935283A19F400DDBA79 /* Int+Extension.swift */; };
1818
88379938283A1A0F00DDBA79 /* String+Extension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88379937283A1A0F00DDBA79 /* String+Extension.swift */; };
19+
88498D4C29A285BE007303B0 /* Logger+Extension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88498D4B29A285BE007303B0 /* Logger+Extension.swift */; };
1920
888C864B29059F6300E86D85 /* NetworkKit in Frameworks */ = {isa = PBXBuildFile; productRef = 888C864A29059F6300E86D85 /* NetworkKit */; };
2021
889714F82932618200D8B1B7 /* DownloadStatus.swift in Sources */ = {isa = PBXBuildFile; fileRef = 889714F72932618200D8B1B7 /* DownloadStatus.swift */; };
2122
88A729AE28264AD100B5FE61 /* LoadifyApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88A729AD28264AD100B5FE61 /* LoadifyApp.swift */; };
@@ -59,6 +60,7 @@
5960
883233862855F34000BF38B5 /* Double+Extension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Double+Extension.swift"; sourceTree = "<group>"; };
6061
88379935283A19F400DDBA79 /* Int+Extension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Int+Extension.swift"; sourceTree = "<group>"; };
6162
88379937283A1A0F00DDBA79 /* String+Extension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "String+Extension.swift"; sourceTree = "<group>"; };
63+
88498D4B29A285BE007303B0 /* Logger+Extension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Logger+Extension.swift"; sourceTree = "<group>"; };
6264
889714F72932618200D8B1B7 /* DownloadStatus.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DownloadStatus.swift; sourceTree = "<group>"; };
6365
88A729AA28264AD100B5FE61 /* Loadify.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Loadify.app; sourceTree = BUILT_PRODUCTS_DIR; };
6466
88A729AD28264AD100B5FE61 /* LoadifyApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoadifyApp.swift; sourceTree = "<group>"; };
@@ -127,6 +129,7 @@
127129
88379935283A19F400DDBA79 /* Int+Extension.swift */,
128130
883233862855F34000BF38B5 /* Double+Extension.swift */,
129131
88379937283A1A0F00DDBA79 /* String+Extension.swift */,
132+
88498D4B29A285BE007303B0 /* Logger+Extension.swift */,
130133
);
131134
path = Extensions;
132135
sourceTree = "<group>";
@@ -416,6 +419,7 @@
416419
88220A89285DC9CC008260DE /* URLViewModel.swift in Sources */,
417420
882ECF9B28CDB55E001F4C7D /* API.swift in Sources */,
418421
88FDA6E02862C80D0028DCE9 /* Errors.swift in Sources */,
422+
88498D4C29A285BE007303B0 /* Logger+Extension.swift in Sources */,
419423
88A729AE28264AD100B5FE61 /* LoadifyApp.swift in Sources */,
420424
88379938283A1A0F00DDBA79 /* String+Extension.swift in Sources */,
421425
88AFF4A528521F1300D00040 /* FileService.swift in Sources */,
@@ -708,7 +712,7 @@
708712
repositoryURL = "https://github.com/VishwaiOSDev/LoggerKit";
709713
requirement = {
710714
kind = upToNextMinorVersion;
711-
minimumVersion = 1.0.0;
715+
minimumVersion = 1.1.1;
712716
};
713717
};
714718
88D9D1E328C39EAB00D6EB79 /* XCRemoteSwiftPackageReference "FontKit" */ = {

Loadify.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Loadify/App/LoadifyApp.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ struct LoadifyApp: App {
1818

1919
init() {
2020
FontKit.registerInter()
21+
Logger.configure()
2122
}
2223

2324
var body: some Scene {
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
//
2+
// Logger+Extension.swift
3+
// Loadify
4+
//
5+
// Created by Vishweshwaran on 19/02/23.
6+
//
7+
8+
import Foundation
9+
import NetworkKit
10+
import LoggerKit
11+
12+
typealias Logger = LoadifyApp.Logger
13+
14+
extension LoadifyApp {
15+
16+
struct Logger: Loggable {
17+
18+
static var logTag: String { "Loadify" }
19+
static var logConfig: LoggerKit.LoggerConfig = .init(enable: true, severity: .info)
20+
21+
static func configure() {
22+
NetworkKit.Logger.logConfig = .init(enable: false)
23+
}
24+
}
25+
}

0 commit comments

Comments
 (0)