Skip to content

Commit

Permalink
default user set to root
Browse files Browse the repository at this point in the history
  • Loading branch information
dcodesdev committed May 31, 2024
1 parent 0a60c09 commit b45ce6c
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "fast-scp"
version = "0.1.3"
version = "0.1.4"
description = "A fast and simple scp CLI tool"
license = "MIT"
repository = "https://github.com/dcodesdev/fast-scp"
Expand Down
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,18 @@ A Rust CLI tool to copy files from your linux remote server to your local machin
## Example

```bash
fast-scp receive <remote-path> <local-path> --host <host> --user <username> --private-key [path-to-private-key]
fast-scp receive <remote-path> <local-path> --host <host>
```

### Parameters

- `remote-path`: The path to the file or directory on the remote server.
- `local-path`: The path to the directory on the local machine where the files will be copied to.
- `host`: The IP address or hostname of the remote server.
- `user` (optional): The username to use to connect to the remote server. Default is `root`.
- `private-key` (optional): The path to the private key to use to connect to the remote server. Default is `~/.ssh/id_rsa`.
- `replace` (optional): If set, the local file will be replaced if it already exists. Default is `false`.

## License

Licensed under MIT License. See [LICENSE](LICENSE) for more information.
7 changes: 6 additions & 1 deletion src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ pub enum Commands {
#[clap(long, help = "Remote host to connect to")]
host: String,

#[clap(short, long, help = "Remote username to connect as")]
#[clap(
short,
long,
help = "Remote username to connect as",
default_value = "root"
)]
user: String,

#[clap(short, long, help = "Path to private key")]
Expand Down

0 comments on commit b45ce6c

Please sign in to comment.