ti fs delete-file
Deletes a remote file or directory. The command alias is ti fs rm.
Syntax
ti fs delete-file
--path <string>
[--dry-run]
[--file-system-id <string>]
[--fs-token <string>]
[--help]
[--recursive]
[--version]
Options
--path <string>: File or directory path in the TiDB Cloud file system. [required]--dry-run: Validate the request without applying changes.--file-system-id <string>: Select the file system. You can also setTI_FS_FILE_SYSTEM_ID.--fs-token <string>: Set the file system user token. If omitted, usesTI_FS_TOKEN.--help: Display help information.--recursive: Delete a directory recursively.--version: Display version information.
For options shared by all commands, see Global options.
Examples
Delete a remote file:
# Remove one object from the selected Filesystem. ti fs delete-file --file-system-id <file-system-id> --path /reports/obsolete.mdDelete a directory recursively:
# Remove a directory and all of its descendants in one request. ti fs delete-file --file-system-id <file-system-id> --path /scratch --recursive