bm diff
Syntax
The bm diff bm computes the differences between two filesystem directories
or Buckit buckets. bm diff lists only those objects which are missing or
which differ in size. bm diff does not compare the contents of
objects.
The following command computes the difference between an object on
a local filesystem and an object in the mydata bucket on the
mybuckit Buckit deployment:
bm diff ~/mydata/myobject.txt mybuckit/mydata/myobject.txt
The bm diff command has the following syntax:
bm [GLOBALFLAGS] diff SOURCE TARGET
Brackets
[]indicate optional parameters.Parameters sharing a line are mutually dependent.
Parameters separated using the pipe
|operator are mutually exclusive.
Copy the example to a text editor and modify as-needed before running the command in the terminal/shell.
Parameters
- SOURCE
Required The object to compare to the
TARGET.For an object from Buckit, specify the
aliasand the full path to that object (e.g. bucket and path to object). For example:bm diff play/mybucket/object.txt ~/mydata/object.txt
For an object from a local filesystem, specify the full path to that object. For example:
bm diff ~/mydata/object.txt play/mybucket/object.txt
- TARGET
Required The object to compare to the
SOURCE.For an object from Buckit, specify the
aliasand the full path to that object (e.g. bucket and path to object). For example:bm diff play/mybucket/object.txt ~/mydata/object.txt
For an object from a local filesystem, specify the full path to that object. For example:
bm diff ~/mydata/object.txt play/mybucket/object.txt
Global Flags
This command supports any of the global flags.
Examples
The following example assumes that the play alias exists in the
bm configuration file. You can
replace play with the alias for your preferred S3-compatible deployment.
See bm alias for more information on aliases.
bm diff play/bucket1 play/bucket2
Behavior
Output Legend
bm diff uses the following legend when formatting the diff output:
FIRST < SECOND - object exists only in FIRST
FIRST > SECOND - object exists only in SECOND
FIRST ! SECOND - Newer object exists in FIRST
S3 Compatibility
The bm commandline tool is built for compatibility with the AWS S3 API and is tested with Buckit and AWS S3 for expected functionality and behavior.
Buckit provides no guarantees for other S3-compatible services, as their S3 API implementation is unknown and therefore unsupported. While bm commands may work as documented, any such usage is at your own risk.