Skip to content

Commit 415273c

Browse files
committed
Rename FormatTable to Display
1 parent 0c02835 commit 415273c

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/CLU/Microsoft.CLU/System.Management.Automation/CLUHost.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,13 +50,13 @@ internal CLUHost(ref string[] args, HostStreamInfo hostStreamInfo)
5050
_doVerbose = Constants.CmdletPreferencesContinue;
5151
}
5252

53-
if (RemoveArgumentIfFound(argList, "formatjson"))
53+
if (RemoveArgumentIfFound(argList, "json"))
5454
{
5555
this.RequestedOutputFormat = OutputFormat.JSON;
5656
}
57-
else if (RemoveArgumentIfFound(argList, "formattable"))
57+
else if (RemoveArgumentIfFound(argList, "display"))
5858
{
59-
this.RequestedOutputFormat = OutputFormat.Formatted;
59+
this.RequestedOutputFormat = OutputFormat.Display;
6060
}
6161

6262
args = argList.ToArray();

src/CLU/Microsoft.CLU/System.Management.Automation/Cmdlet.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ internal void FlushPipeline(LocalPackage package)
154154
internal bool ShouldWriteJsonOutput()
155155
{
156156
var requestedOutputFormat = CommandRuntime.Host.RequestedOutputFormat;
157-
return (CommandRuntime.Host.IsOutputRedirected && requestedOutputFormat != OutputFormat.Formatted)
157+
return (CommandRuntime.Host.IsOutputRedirected && requestedOutputFormat == OutputFormat.Auto)
158158
|| requestedOutputFormat == OutputFormat.JSON;
159159
}
160160
protected void WriteProgress(ProgressRecord progressRecord) { if (progressRecord != null) CommandRuntime.WriteProgress(progressRecord); }

src/CLU/Microsoft.CLU/System.Management.Automation/OutputFormat.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ public enum OutputFormat
99
{
1010
Auto = 0,
1111
JSON = 1,
12-
Formatted = 2
12+
Display = 2
1313
}
1414
}

0 commit comments

Comments
 (0)