bump version with --start
This commit is contained in:
parent
efaf30a863
commit
1121a7b290
11
index.ts
11
index.ts
|
|
@ -244,6 +244,7 @@ function showHelp(): void {
|
||||||
|
|
||||||
Usage:
|
Usage:
|
||||||
csharpierd <filename> < input.cs Format C# code from stdin
|
csharpierd <filename> < input.cs Format C# code from stdin
|
||||||
|
csharpierd --start Start and prewarm the server
|
||||||
csharpierd --status Show server status
|
csharpierd --status Show server status
|
||||||
csharpierd --stop Stop the background server
|
csharpierd --stop Stop the background server
|
||||||
csharpierd --help Show this help message
|
csharpierd --help Show this help message
|
||||||
|
|
@ -254,6 +255,9 @@ Description:
|
||||||
automatically shuts down after 1 hour of inactivity.
|
automatically shuts down after 1 hour of inactivity.
|
||||||
|
|
||||||
Examples:
|
Examples:
|
||||||
|
# Start and prewarm the server
|
||||||
|
csharpierd --start
|
||||||
|
|
||||||
# Format a C# file
|
# Format a C# file
|
||||||
csharpierd Program.cs < Program.cs
|
csharpierd Program.cs < Program.cs
|
||||||
|
|
||||||
|
|
@ -379,6 +383,13 @@ async function main() {
|
||||||
process.exit(0);
|
process.exit(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Handle --start flag
|
||||||
|
if (arg === "--start") {
|
||||||
|
await ensureServer();
|
||||||
|
console.error("CSharpier server is ready");
|
||||||
|
process.exit(0);
|
||||||
|
}
|
||||||
|
|
||||||
// Normal formatting mode
|
// Normal formatting mode
|
||||||
const fileName = arg;
|
const fileName = arg;
|
||||||
if (!fileName) {
|
if (!fileName) {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "csharpierd",
|
"name": "csharpierd",
|
||||||
"version": "1.0.3",
|
"version": "1.0.4",
|
||||||
"description": "A persistent CSharpier formatting daemon with automatic server management and idle timeout",
|
"description": "A persistent CSharpier formatting daemon with automatic server management and idle timeout",
|
||||||
"module": "index.ts",
|
"module": "index.ts",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue