Skip to content

Commit

Permalink
Merge pull request #22 from taji-taji/refactor-danger-periphery-struc…
Browse files Browse the repository at this point in the history
…t-to-enum

Refactor danger periphery struct to enum
  • Loading branch information
taji-taji authored Aug 14, 2022
2 parents 093e514 + aafc0f6 commit 12f3170
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions Sources/DangerSwiftPeriphery/DangerPeriphery.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,7 @@

import Danger

public struct DangerPeriphery {
@discardableResult
public static func scan(peripheryExecutable: String = "swift run periphery",
shouldComment: Bool = true,
verbose: Bool = false) -> Result<[Violation] , Error> {
scan(peripheryExecutable: peripheryExecutable,
arguments: [] as [String],
shouldComment: shouldComment,
verbose: verbose)
}

public enum DangerPeriphery {
@discardableResult
public static func scan(peripheryExecutable: String = "swift run periphery",
@PeripheryArgumentsBuilder arguments: () -> [String],
Expand All @@ -42,7 +32,7 @@ public struct DangerPeriphery {

@discardableResult
public static func scan(peripheryExecutable: String = "swift run periphery",
arguments: [String],
arguments: [String] = [],
shouldComment: Bool = true,
verbose: Bool = false) -> Result<[Violation] , Error> {
Logger.shared.verbose = verbose
Expand Down

0 comments on commit 12f3170

Please sign in to comment.