Skip to content
This repository was archived by the owner on Oct 8, 2024. It is now read-only.

Commit 2266673

Browse files
committed
update
1 parent f510397 commit 2266673

9 files changed

+0
-65
lines changed

RsyncOSX/ReadConfigurationJSON.swift

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -8,52 +8,12 @@
88
import Combine
99
import Foundation
1010

11-
/*
12-
struct UniqueserversandLogins: Hashable {
13-
var offsiteUsername: String?
14-
var offsiteServer: String?
15-
16-
init(_ username: String,
17-
_ servername: String)
18-
{
19-
offsiteServer = servername
20-
offsiteUsername = username
21-
}
22-
23-
func hash(into hasher: inout Hasher) {
24-
hasher.combine(offsiteUsername)
25-
hasher.combine(offsiteServer)
26-
}
27-
}
28-
*/
2911
class ReadConfigurationJSON: NamesandPaths {
3012
var configurations: [Configuration]?
3113
var filenamedatastore = [SharedReference.shared.fileconfigurationsjson]
3214
var subscriptons = Set<AnyCancellable>()
3315
var validhiddenIDs = Set<Int>()
3416

35-
/*
36-
func setuniqueserversandlogins() -> [UniqueserversandLogins]? {
37-
let configs = configurations?.filter {
38-
SharedReference.shared.synctasks.contains($0.task)
39-
}
40-
guard configs?.count ?? 0 > 0 else { return nil }
41-
var uniqueserversandlogins = [UniqueserversandLogins]()
42-
for i in 0 ..< (configs?.count ?? 0) {
43-
if let config = configs?[i] {
44-
if config.offsiteUsername.isEmpty == false, config.offsiteServer.isEmpty == false {
45-
let record = UniqueserversandLogins(config.offsiteUsername, config.offsiteServer)
46-
if uniqueserversandlogins.filter({ ($0.offsiteUsername == record.offsiteUsername) &&
47-
($0.offsiteServer == record.offsiteServer)
48-
}).count == 0 {
49-
uniqueserversandlogins.append(record)
50-
}
51-
}
52-
}
53-
}
54-
return uniqueserversandlogins
55-
}
56-
*/
5717
init(_ profile: String?) {
5818
super.init(.configurations)
5919
filenamedatastore.publisher

RsyncOSX/ReadScheduleJSON.swift

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ class ReadScheduleJSON: NamesandPaths {
3535
.sink { completion in
3636
switch completion {
3737
case .finished:
38-
// print("The publisher finished normally.")
3938
return
4039
case let .failure(error):
4140
let error = error as NSError
@@ -47,7 +46,6 @@ class ReadScheduleJSON: NamesandPaths {
4746
var schedule = ConfigurationSchedule(data[i])
4847
schedule.profilename = profile
4948
// Validate that the hidden ID is OK,
50-
// schedule != Scheduletype.stopped.rawValue, logs count > 0
5149
if let validhiddenID = validhiddenID {
5250
if validhiddenID.contains(schedule.hiddenID) {
5351
schedules.append(schedule)

RsyncOSX/RsyncAsync.swift

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,6 @@ final class RsyncAsync: Errors {
7474
}
7575
}
7676

77-
// Terminate Process, used when user Aborts task.
78-
func abortProcess() {
79-
_ = InterruptProcess()
80-
}
81-
8277
init(arguments: [String]?,
8378
processtermination: @escaping ([String]?) -> Void)
8479
{

RsyncOSX/RsyncProcess.swift

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,6 @@ final class RsyncProcess: Errors {
111111
}
112112
}
113113

114-
// Terminate Process, used when user Aborts task.
115-
func abortProcess() {
116-
_ = InterruptProcess()
117-
}
118-
119114
init(arguments: [String]?,
120115
config: Configuration?,
121116
processtermination: @escaping () -> Void,

RsyncOSX/RsyncProcessAsync.swift

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -96,11 +96,6 @@ final class RsyncProcessAsync: Errors {
9696
}
9797
}
9898

99-
// Terminate Process, used when user Aborts task.
100-
func abortProcess() {
101-
_ = InterruptProcess()
102-
}
103-
10499
init(arguments: [String]?,
105100
config: Configuration?,
106101
processtermination: @escaping ([String]?) -> Void)

RsyncOSX/ViewControllerExtensions.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,6 @@ extension VcMain {
4141
as? NSViewController)
4242
}
4343

44-
// AssistID
45-
var viewControllerAssist: NSViewController? {
46-
return (sheetviewstoryboard?.instantiateController(withIdentifier: "AssistID")
47-
as? NSViewController)
48-
}
49-
5044
// Profile
5145
var viewControllerProfile: NSViewController? {
5246
return (sheetviewstoryboard?.instantiateController(withIdentifier: "ProfileID")

RsyncOSX/WriteConfigurationJSON.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ class WriteConfigurationJSON: NamesandPaths {
5252
.sink(receiveCompletion: { completion in
5353
switch completion {
5454
case .finished:
55-
// print("The publisher finished normally.")
5655
return
5756
case let .failure(error):
5857
let error = error as NSError

RsyncOSX/WriteScheduleJSON.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ class WriteScheduleJSON: NamesandPaths {
5151
.sink(receiveCompletion: { completion in
5252
switch completion {
5353
case .finished:
54-
// print("The publisher finished normally.")
5554
return
5655
case let .failure(error):
5756
let error = error as NSError
11.5 MB
Binary file not shown.

0 commit comments

Comments
 (0)