(cmd *cobra.Command, args []string)
| 221 | } |
| 222 | |
| 223 | func fileRmRun(cmd *cobra.Command, args []string) error { |
| 224 | path, err := fixRelativePaths(args[0]) |
| 225 | if err != nil { |
| 226 | return err |
| 227 | } |
| 228 | recursive, err := cmd.Flags().GetBool("recursive") |
| 229 | if err != nil { |
| 230 | return err |
| 231 | } |
| 232 | |
| 233 | err = wshclient.FileDeleteCommand(RpcClient, wshrpc.CommandDeleteFileData{Path: path, Recursive: recursive}, &wshrpc.RpcOpts{Timeout: fileTimeout}) |
| 234 | if err != nil { |
| 235 | return fmt.Errorf("removing file: %w", err) |
| 236 | } |
| 237 | |
| 238 | return nil |
| 239 | } |
| 240 | |
| 241 | func fileWriteRun(cmd *cobra.Command, args []string) error { |
| 242 | path, err := fixRelativePaths(args[0]) |
nothing calls this directly
no test coverage detected