-
-
Notifications
You must be signed in to change notification settings - Fork 165
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fullscreen command: support [on|off] argument
- Loading branch information
1 parent
a53074e
commit 68df46c
Showing
5 changed files
with
49 additions
and
9 deletions.
There are no files selected for viewing
20 changes: 20 additions & 0 deletions
20
LocalPackage/Sources/Common/cmdArgs/FullscreenCmdArgs.swift
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,20 @@ | ||
public struct FullscreenCmdArgs: CmdArgs, RawCmdArgs { | ||
public init() {} | ||
public static let parser: CmdParser<Self> = cmdParser( | ||
kind: .fullscreen, | ||
allowInConfig: true, | ||
help: """ | ||
USAGE: fullscreen [-h|--help] [on|off] | ||
OPTIONS: | ||
-h, --help Print help | ||
ARGUMENTS: | ||
[on|off] 'on' means enter fullscreen mode. 'off' means exit fullscreen mode. | ||
Toggle between the two if not specified | ||
""", | ||
options: [:], | ||
arguments: [ArgParser(\.toggle, parseToggleEnum)] | ||
) | ||
public var toggle: ToggleEnum = .toggle | ||
} |
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
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