Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/Tools/dotnet-gcdump/CommandLine/CollectCommandHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ private static async Task<int> Collect(CancellationToken ct, IConsole console, i

if (processId == 0)
{
Console.Out.WriteLine($"-p|--process-id is required");
Console.Out.WriteLine("-p|--process-id is required");
return -1;
}

Expand Down Expand Up @@ -95,12 +95,12 @@ private static async Task<int> Collect(CancellationToken ct, IConsole console, i
}
else if (ct.IsCancellationRequested)
{
Console.Out.WriteLine($"\tCancelled.");
Console.Out.WriteLine("\tCancelled.");
return -1;
}
else
{
Console.Out.WriteLine($"\tFailed to collect gcdump. Try running with '-v' for more information.");
Console.Out.WriteLine("\tFailed to collect gcdump. Try running with '-v' for more information.");
return -1;
}
}
Expand Down Expand Up @@ -142,15 +142,15 @@ public static Command CollectCommand() =>
private static Option ProcessIdOption() =>
new Option(
aliases: new[] { "-p", "--process-id" },
description: "The process id to collect the gcdump.")
description: "The process id to collect the gcdump from.")
{
Argument = new Argument<int>(name: "pid", defaultValue: 0),
};

private static Option NameOption() =>
new Option(
aliases: new[] { "-n", "--name" },
description: "The name of the process to collect the gcdump.")
description: "The name of the process to collect the gcdump from.")
{
Argument = new Argument<string>(name: "name")
};
Expand All @@ -166,7 +166,7 @@ private static Option OutputPathOption() =>
private static Option VerboseOption() =>
new Option(
aliases: new[] { "-v", "--verbose" },
description: $"Output the log while collecting the gcdump.")
description: "Output the log while collecting the gcdump.")
{
Argument = new Argument<bool>(name: "verbose", defaultValue: false)
};
Expand Down
6 changes: 3 additions & 3 deletions src/Tools/dotnet-gcdump/CommandLine/ReportCommandHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ private static Task<int> Report(CancellationToken ct, IConsole console, FileInfo
//
if (gcdump_filename == null && !processId.HasValue)
{
Console.Error.WriteLine("<gcdump_filename> or -p|process-id is required");
Console.Error.WriteLine("<gcdump_filename> or -p|--process-id is required");
return Task.FromResult(-1);
}

if (gcdump_filename != null && processId.HasValue)
{
Console.Error.WriteLine("Specify only one of -f|--file or -p|process-id.");
Console.Error.WriteLine("Specify only one of -f|--file or -p|--process-id.");
return Task.FromResult(-1);
}

Expand Down Expand Up @@ -109,7 +109,7 @@ private static Argument<FileInfo> FileNameArgument() =>
}.ExistingOnly();

private static Option<int> ProcessIdOption() =>
new Option<int>(new[] { "-p", "--process-id" }, "The process id to collect the trace.");
new Option<int>(new[] { "-p", "--process-id" }, "The process id to collect the gcdump from.");

private static Option<ReportType> ReportTypeOption() =>
new Option<ReportType>(new[] { "-t", "--report-type" }, "The type of report to generate. Available options: heapstat (default)")
Expand Down
2 changes: 1 addition & 1 deletion src/Tools/dotnet-gcdump/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public static Task<int> Main(string[] args)
{
var parser = new CommandLineBuilder()
.AddCommand(CollectCommandHandler.CollectCommand())
.AddCommand(ProcessStatusCommandHandler.ProcessStatusCommand("Lists the dotnet processes that gcdumps can be collected"))
.AddCommand(ProcessStatusCommandHandler.ProcessStatusCommand("Lists the dotnet processes that gcdumps can be collected from"))
.AddCommand(ReportCommandHandler.ReportCommand())
.UseDefaults()
.Build();
Expand Down