diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-01-09 23:48:17 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-01-09 23:48:17 +0800 |
| commit | 6dedba9e3cedf6463f25460eba84111d6a0bd0dd (patch) | |
| tree | 4dcc6855ada5b28e20835ab60800c1028e505f7a /CommandLineWrapperExample | |
| parent | 6b9268d2d88c81c18f2cc21e343d321989dad99c (diff) | |
Add command line wrapper for JVCS operations
Diffstat (limited to 'CommandLineWrapperExample')
| -rw-r--r-- | CommandLineWrapperExample/Program.cs | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/CommandLineWrapperExample/Program.cs b/CommandLineWrapperExample/Program.cs index e69de29..64d4e80 100644 --- a/CommandLineWrapperExample/Program.cs +++ b/CommandLineWrapperExample/Program.cs @@ -0,0 +1,23 @@ +internal class Program +{ + private static string currentDirectory = "/.Temp/Current/"; + private static string CorrectCurrentDirectory() + { + var current = Directory.GetCurrentDirectory() + currentDirectory; + if (!Directory.Exists(current)) + Directory.CreateDirectory(current); + Directory.SetCurrentDirectory(current); + return current; + } + + private static async Task Main(string[] args) + { + var current = CorrectCurrentDirectory(); + + // Use Current as the workspace directory + var workspace = new JVCSWorkspace(); + await workspace.InitializeAsync(current); + + await workspace.Login("catilgrass", "127.0.0.1"); + } +} |
