Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

Update docs - fixes #32

Nick Craig-Wooda5974999eb3c
diff --git a/README.md b/README.md
index dc8c3756d..4abecd7ca 100644
--- a/README.md
+++ b/README.md
@@ -82,21 +82,26 @@ MD5SUM. Doesn't delete files from the destination.
Sync the source to the destination. Doesn't transfer
unchanged files, testing first by modification time then by
-MD5SUM. Deletes any files that exist in source that don't
+size. Deletes any files that exist in source that don't
exist in destination. Since this can cause data loss, test
first with the `--dry-run` flag.
rclone ls [remote:path]
-List all the objects in the the path with sizes.
+List all the objects in the the path with size and path.
+
+ rclone lsd [remote:path]
+
+List all directories/containers/buckets in the the path.
rclone lsl [remote:path]
-List all the objects in the the path with sizes and timestamps.
+List all the objects in the the path with modification time, size and path.
- rclone lsd [remote:path]
+ rclone md5sum [remote:path]
-List all directories/objects/buckets in the the path.
+Produces an md5sum file for all the objects in the path. This
+is in the same format as the standard md5sum tool produces.
rclone mkdir remote:path
@@ -117,10 +122,13 @@ Checks the files in the source and destination match. It
compares sizes and MD5SUMs and prints a report of files which
don't match. It doesn't alter the source or destination.
- rclone md5sum remote:path
+ rclone config
+
+Enter an interactive configuration session.
+
+ rclone help
-Produces an md5sum file for all the objects in the path. This is in
-the same format as the standard md5sum tool produces.
+This help.
General options:
diff --git a/docs/content/docs.md b/docs/content/docs.md
index a47e6dd97..95da136bd 100644
--- a/docs/content/docs.md
+++ b/docs/content/docs.md
@@ -65,21 +65,26 @@ MD5SUM. Doesn't delete files from the destination.
Sync the source to the destination. Doesn't transfer
unchanged files, testing first by modification time then by
-MD5SUM. Deletes any files that exist in source that don't
+size. Deletes any files that exist in source that don't
exist in destination. Since this can cause data loss, test
-first with the -dry-run flag.
+first with the `--dry-run` flag.
rclone ls [remote:path]
-List all the objects in the the path with sizes.
+List all the objects in the the path with size and path.
+
+ rclone lsd [remote:path]
+
+List all directories/containers/buckets in the the path.
rclone lsl [remote:path]
-List all the objects in the the path with sizes and timestamps.
+List all the objects in the the path with modification time, size and path.
- rclone lsd [remote:path]
+ rclone md5sum [remote:path]
-List all directories/objects/buckets in the the path.
+Produces an md5sum file for all the objects in the path. This
+is in the same format as the standard md5sum tool produces.
rclone mkdir remote:path
@@ -100,11 +105,13 @@ Checks the files in the source and destination match. It
compares sizes and MD5SUMs and prints a report of files which
don't match. It doesn't alter the source or destination.
- rclone md5sum remote:path
+ rclone config
+
+Enter an interactive configuration session.
+
+ rclone help
-Produces an md5sum file for all the objects in the path. This is in
-the same format as the standard md5sum tool produces.
-General options:
+This help.
```
--bwlimit=0: Bandwidth limit in kBytes/s, or use suffix K|M|G
diff --git a/notes.txt b/notes.txt
index 5d7f6def4..eb5acc9e2 100644
--- a/notes.txt
+++ b/notes.txt
@@ -19,30 +19,23 @@ Todo
* if object.PseudoDirectory {
* fmt.Printf("%9s %19s %s\n", "Directory", "-", fs.Remote())
* Make Account wrapper
- * limit bandwidth for a pool of all individual connectinos
- * do timeouts by setting a limit, seeing whether io has happened
- and resetting it if it has
* make Account do progress meter
- * Make logging controllable with flags (mostly done)
* -timeout: Make all timeouts be settable with command line parameters
- * Windows paths? Do we need to translate / and \?
- * Make a fs.Errorf and count errors and log them at a different level
* Add max object size to fs metadata - 5GB for swift, infinite for local, ? for s3
* tie into -max-size flag
* FIXME Make NewFs to return err.IsAnObject so can put the LimitedFs
creation in common code? Or try for as much as possible?
* FIXME Account all the transactons (ls etc) using a different
Roundtripper wrapper which wraps the transactions?
- * FIXME write tests for local file system
- * FIXME implement tests for single file operations in rclonetest
- * Need to make directory objects otherwise can't upload an empty directory
- * Or could upload empty directories only?
More rsync features
* include
* exclude
* max size
- * bandwidth limit
+ * -c, --checksum skip based on checksum, not mod-time & size
+
+Ideas for flags
+ * --retries N flag which would make rclone retry a sync until successful or it tried N times.
Ideas
* could do encryption - put IV into metadata?
@@ -55,13 +48,6 @@ Ideas
* control times sync (which is slow with some remotes) with -a --archive flag?
* Copy a glob pattern - could do with LimitedFs
-s3
- * Can maybe set last modified?
- * https://forums.aws.amazon.com/message.jspa?messageID=214062
- * Otherwise can set metadata
- * Returns etag and last modified in bucket list
-
Bugs
* Non verbose - not sure number transferred got counted up? CHECK
* When doing copy it recurses the whole of the destination FS which isn't necessary
-
diff --git a/rclone.go b/rclone.go
index 4945fb393..2cbf39792 100644
--- a/rclone.go
+++ b/rclone.go
@@ -59,11 +59,11 @@ func (cmd *Command) checkArgs(args []string) {
var Commands = []Command{
{
Name: "copy",
- ArgsHelp: "source://path dest://path",
+ ArgsHelp: "source:path dest:path",
Help: `
Copy the source to the destination. Doesn't transfer
unchanged files, testing first by modification time then by
- MD5SUM. Doesn't delete files from the destination.`,
+ size. Doesn't delete files from the destination.`,
Run: func(fdst, fsrc fs.Fs) {
err := fs.Sync(fdst, fsrc, false)
if err != nil {
@@ -75,11 +75,11 @@ var Commands = []Command{
},
{
Name: "sync",
- ArgsHelp: "source://path dest://path",
+ ArgsHelp: "source:path dest:path",
Help: `
Sync the source to the destination. Doesn't transfer
unchanged files, testing first by modification time then by
- MD5SUM. Deletes any files that exist in source that don't
+ size. Deletes any files that exist in source that don't
exist in destination. Since this can cause data loss, test
first with the --dry-run flag.`,
Run: func(fdst, fsrc fs.Fs) {
@@ -93,7 +93,7 @@ var Commands = []Command{
},
{
Name: "ls",
- ArgsHelp: "[remote://path]",
+ ArgsHelp: "[remote:path]",
Help: `
List all the objects in the the path with size and path.`,
Run: func(fdst, fsrc fs.Fs) {
@@ -107,7 +107,7 @@ var Commands = []Command{
},
{
Name: "lsd",
- ArgsHelp: "[remote://path]",
+ ArgsHelp: "[remote:path]",
Help: `
List all directories/containers/buckets in the the path.`,
Run: func(fdst, fsrc fs.Fs) {
@@ -121,7 +121,7 @@ var Commands = []Command{
},
{
Name: "lsl",
- ArgsHelp: "[remote://path]",
+ ArgsHelp: "[remote:path]",
Help: `
List all the objects in the the path with modification time, size and path.`,
Run: func(fdst, fsrc fs.Fs) {
@@ -135,9 +135,10 @@ var Commands = []Command{
},
{
Name: "md5sum",
- ArgsHelp: "[remote://path]",
+ ArgsHelp: "[remote:path]",
Help: `
- Produces an md5sum file for all the objects in the path.`,
+ Produces an md5sum file for all the objects in the path. This
+ is in the same format as the standard md5sum tool produces.`,
Run: func(fdst, fsrc fs.Fs) {
err := fs.Md5sum(fdst, os.Stdout)
if err != nil {
@@ -149,7 +150,7 @@ var Commands = []Command{
},
{
Name: "mkdir",
- ArgsHelp: "remote://path",
+ ArgsHelp: "remote:path",
Help: `
Make the path if it doesn't already exist`,
Run: func(fdst, fsrc fs.Fs) {
@@ -163,7 +164,7 @@ var Commands = []Command{
},
{
Name: "rmdir",
- ArgsHelp: "remote://path",
+ ArgsHelp: "remote:path",
Help: `
Remove the path. Note that you can't remove a path with
objects in it, use purge for that.`,
@@ -178,7 +179,7 @@ var Commands = []Command{
},
{
Name: "purge",
- ArgsHelp: "remote://path",
+ ArgsHelp: "remote:path",
Help: `
Remove the path and all of its contents.`,
Run: func(fdst, fsrc fs.Fs) {
@@ -192,7 +193,7 @@ var Commands = []Command{
},
{
Name: "check",
- ArgsHelp: "source://path dest://path",
+ ArgsHelp: "source:path dest:path",
Help: `
Checks the files in the source and destination match. It
compares sizes and MD5SUMs and prints a report of files which