Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

Commit

Permalink
Merge development into production
Browse files Browse the repository at this point in the history
  • Loading branch information
sammyd committed Apr 12, 2023
2 parents 7ec87e4 + 1bc8abd commit 9f5e61d
Show file tree
Hide file tree
Showing 8 changed files with 32 additions and 22 deletions.
10 changes: 8 additions & 2 deletions Emitron/Emitron.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1647,7 +1647,7 @@
attributes = {
LastSwiftUpdateCheck = 1130;
LastUpgradeCheck = 1200;
ORGANIZATIONNAME = Razeware;
ORGANIZATIONNAME = "Kodeco Inc";
TargetAttributes = {
225670A6240AFD3100BD05AE = {
CreatedOnToolsVersion = 11.3.1;
Expand Down Expand Up @@ -2090,6 +2090,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KFCNEC27GU;
INFOPLIST_FILE = emitronScreenshots/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -2109,6 +2110,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KFCNEC27GU;
INFOPLIST_FILE = emitronScreenshots/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -2128,6 +2130,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KFCNEC27GU;
INFOPLIST_FILE = emitronScreenshots/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down Expand Up @@ -2236,6 +2239,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KFCNEC27GU;
INFOPLIST_FILE = emitronTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -2256,6 +2260,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KFCNEC27GU;
INFOPLIST_FILE = emitronTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -2276,6 +2281,7 @@
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = KFCNEC27GU;
INFOPLIST_FILE = emitronTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down Expand Up @@ -2555,7 +2561,7 @@
repositoryURL = "https://github.com/groue/GRDB.swift.git";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 5.0.0;
minimumVersion = 5.26.1;
};
};
/* End XCRemoteSwiftPackageReference section */
Expand Down
10 changes: 5 additions & 5 deletions Emitron/Emitron/Downloads/DownloadService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -380,15 +380,15 @@ extension DownloadService {
private func prepareDownloadDirectory() {
let fileManager = FileManager.default
do {
if !fileManager.fileExists(atPath: URL.downloadsDirectory.path) {
try fileManager.createDirectory(at: .downloadsDirectory, withIntermediateDirectories: false)
if !fileManager.fileExists(atPath: URL.userDownloadsDirectory.path) {
try fileManager.createDirectory(at: .userDownloadsDirectory, withIntermediateDirectories: false)
}
var values = URLResourceValues()
values.isExcludedFromBackup = true
var downloadsDirectory = URL.downloadsDirectory
var downloadsDirectory = URL.userDownloadsDirectory
try downloadsDirectory.setResourceValues(values)
#if DEBUG
print("Download directory located at: \(URL.downloadsDirectory.path)")
print("Download directory located at: \(URL.userDownloadsDirectory.path)")
#endif
} catch {
preconditionFailure("Unable to prepare downloads directory: \(error)")
Expand All @@ -397,7 +397,7 @@ extension DownloadService {

private func deleteExistingDownloads() {
do {
try FileManager.removeExistingFile(at: .downloadsDirectory)
try FileManager.removeExistingFile(at: .userDownloadsDirectory)
prepareDownloadDirectory()
} catch {
preconditionFailure("Unable to delete the contents of the downloads directory: \(error)")
Expand Down
2 changes: 1 addition & 1 deletion Emitron/Emitron/Extensions/FileManager+Extensions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public extension FileManager {

// MARK: - Emitron
extension URL {
static var downloadsDirectory: URL {
static var userDownloadsDirectory: URL {
FileManager.userDocumentsDirectory.appendingPathComponent("downloads", isDirectory: true)
}
}
2 changes: 1 addition & 1 deletion Emitron/Emitron/Models/Download.swift
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ struct Download: Codable {
var ordinal: Int = 0 // We copy this from the Content, and it is used to sort the queue

var localURL: URL? {
fileName.map(URL.downloadsDirectory.appendingPathComponent)
fileName.map(URL.userDownloadsDirectory.appendingPathComponent)
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ struct FiltersHeaderView: View {
.overlay(
RoundedRectangle(cornerRadius: Layout.cornerRadius)
.stroke(Color.borderColor, lineWidth: 1)
.padding(1)
)
}
.accessibility(label: Text(filterGroup.type.name))
Expand Down
3 changes: 3 additions & 0 deletions Emitron/Emitron/UI/Shared/Content List/CardView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -90,12 +90,15 @@ struct CardView: View {
.padding([.bottom], 20)

progressBar
.padding([.leading], 3)
.padding([.bottom], 1)
}
.background(Color.cardBackground)
.cornerRadius(7)
.overlay(
RoundedRectangle(cornerRadius: 6)
.stroke(Color.borderColor, lineWidth: 1)
.padding(1)
)
.onAppear {
dynamicContentViewModel.initialiseIfRequired()
Expand Down
20 changes: 10 additions & 10 deletions Emitron/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ GEM
artifactory (3.0.15)
atomos (0.1.3)
aws-eventstream (1.2.0)
aws-partitions (1.705.0)
aws-partitions (1.716.0)
aws-sdk-core (3.170.0)
aws-eventstream (~> 1, >= 1.0.2)
aws-partitions (~> 1, >= 1.651.0)
Expand All @@ -17,7 +17,7 @@ GEM
aws-sdk-kms (1.62.0)
aws-sdk-core (~> 3, >= 3.165.0)
aws-sigv4 (~> 1.1)
aws-sdk-s3 (1.119.0)
aws-sdk-s3 (1.119.1)
aws-sdk-core (~> 3, >= 3.165.0)
aws-sdk-kms (~> 1)
aws-sigv4 (~> 1.4)
Expand Down Expand Up @@ -66,7 +66,7 @@ GEM
faraday_middleware (1.2.0)
faraday (~> 1.0)
fastimage (2.2.6)
fastlane (2.211.0)
fastlane (2.212.1)
CFPropertyList (>= 2.3, < 4.0.0)
addressable (>= 2.8, < 3.0.0)
artifactory (~> 3.0)
Expand Down Expand Up @@ -106,9 +106,9 @@ GEM
xcpretty (~> 0.3.0)
xcpretty-travis-formatter (>= 0.0.3)
gh_inspector (1.1.3)
google-apis-androidpublisher_v3 (0.33.0)
google-apis-androidpublisher_v3 (0.34.0)
google-apis-core (>= 0.9.1, < 2.a)
google-apis-core (0.10.0)
google-apis-core (0.11.0)
addressable (~> 2.5, >= 2.5.1)
googleauth (>= 0.16.2, < 2.a)
httpclient (>= 2.8.1, < 3.a)
Expand All @@ -117,10 +117,10 @@ GEM
retriable (>= 2.0, < 4.a)
rexml
webrick
google-apis-iamcredentials_v1 (0.16.0)
google-apis-core (>= 0.9.1, < 2.a)
google-apis-playcustomapp_v1 (0.12.0)
google-apis-core (>= 0.9.1, < 2.a)
google-apis-iamcredentials_v1 (0.17.0)
google-apis-core (>= 0.11.0, < 2.a)
google-apis-playcustomapp_v1 (0.13.0)
google-apis-core (>= 0.11.0, < 2.a)
google-apis-storage_v1 (0.19.0)
google-apis-core (>= 0.9.0, < 2.a)
google-cloud-core (1.6.0)
Expand Down Expand Up @@ -160,7 +160,7 @@ GEM
naturally (2.2.1)
optparse (0.1.1)
os (1.1.4)
plist (3.6.0)
plist (3.7.0)
public_suffix (5.0.1)
rake (13.0.6)
representable (3.2.0)
Expand Down
6 changes: 3 additions & 3 deletions Emitron/emitronTests/Downloads/DownloadServiceTest.swift
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class DownloadServiceTest: XCTestCase, DatabaseTestCase {
try super.tearDownWithError()
videoService.reset()
try FileManager.removeExistingFile(
at: .downloadsDirectory.appendingPathComponent("sample_file")
at: .userDownloadsDirectory.appendingPathComponent("sample_file")
)
App.objects.settingsManager.resetAll()
}
Expand Down Expand Up @@ -336,7 +336,7 @@ class DownloadServiceTest: XCTestCase, DatabaseTestCase {
//: Download directory
func testCreatesDownloadDirectory() throws {
XCTAssert(
try URL.downloadsDirectory.resourceValues(forKeys: [.isExcludedFromBackupKey]).isExcludedFromBackup == true
try URL.userDownloadsDirectory.resourceValues(forKeys: [.isExcludedFromBackupKey]).isExcludedFromBackup == true
)
}

Expand Down Expand Up @@ -576,7 +576,7 @@ private extension DownloadServiceTest {
}

var sampleFileURL: URL {
.downloadsDirectory.appendingPathComponent("sample_file")
.userDownloadsDirectory.appendingPathComponent("sample_file")
}

var sampleFileExists: Bool {
Expand Down

0 comments on commit 9f5e61d

Please sign in to comment.