fix: fix cli completion stuff
This commit is contained in:
2
.envrc
2
.envrc
@@ -7,3 +7,5 @@ else
|
||||
echo 'while direnv evaluated .envrc, could not find the command "lorri" [https://github.com/nix-community/lorri]'
|
||||
use nix
|
||||
fi
|
||||
|
||||
eval "$shellHook"
|
||||
@@ -17,6 +17,7 @@ mkShell {
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
export PATH="$PWD/src/bin/Debug/net9.0:$PATH"
|
||||
# export S3_URL="https://s3.ob-ceph.local"
|
||||
# export S3_URL="http://10.255.241.30:30080"
|
||||
export S3_URL="http://127.0.0.1:9000"
|
||||
|
||||
12
src/Cli.fs
12
src/Cli.fs
@@ -84,13 +84,13 @@ let argParser: Arg<Command * int> =
|
||||
|> defaultValue 1
|
||||
|
||||
let! mainCommand =
|
||||
cmd "init" "i" "Initialize new archive" |>> CmdType.InitCmd
|
||||
<|> (cmd "copy" "cp" "Copy between archives with optional compression"
|
||||
cmd "init" null "Initialize new archive" |>> CmdType.InitCmd
|
||||
<|> (cmd "copy" null "Copy between archives with optional compression"
|
||||
|>> CmdType.CopyCmd)
|
||||
<|> (cmd "diff" "d" "Compare archives or data arrays" |>> CmdType.DiffCmd)
|
||||
<|> (cmd "add" "a" "Add data to R3 archive" |>> CmdType.AddCmd)
|
||||
<|> (cmd "rm" "r" "Delete objects" |>> CmdType.RmCmd)
|
||||
<|> (cmd "purge" "p" "Delete entire dataset" |>> CmdType.PurgeCmd)
|
||||
<|> (cmd "diff" null "Compare archives or data arrays" |>> CmdType.DiffCmd)
|
||||
<|> (cmd "add" null "Add data to R3 archive" |>> CmdType.AddCmd)
|
||||
<|> (cmd "rm" null "Delete objects" |>> CmdType.RmCmd)
|
||||
<|> (cmd "purge" null "Delete entire dataset" |>> CmdType.PurgeCmd)
|
||||
<|> (error "Invalid or missing command")
|
||||
|
||||
match mainCommand with
|
||||
|
||||
@@ -49,4 +49,4 @@ let executeCommand (ct: System.Threading.CancellationToken) (command: Command *
|
||||
}
|
||||
|
||||
[<EntryPoint>]
|
||||
let main argv = run "Tzar" argParser argv executeCommand
|
||||
let main argv = run "tzar" argParser argv executeCommand
|
||||
@@ -3,6 +3,7 @@
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<AssemblyName>tzar</AssemblyName>
|
||||
<RestorePackagesWithLockFile>true</RestorePackagesWithLockFile>
|
||||
<Version>1.1.0</Version>
|
||||
<RootNamespace>Tzar</RootNamespace>
|
||||
|
||||
Reference in New Issue
Block a user