API Referenece
RcloneInterface._collectexecoutput — Method_collectexecoutput(exec::Cmd)Run the command and return the dominant output stream as a string.
RcloneInterface._readexecoutput — Method_readexecoutput(exec::Cmd) -> (stdout_lines, stderr_lines)Capture stdout and stderr as Vector{String}.
RcloneInterface.rclone_check — Methodrclone_check(src::AbstractString, dest::AbstractString; kwargs...)Verify that files in source and destination match (size + hash by default).
Returns the raw output (useful for parsing mismatch reports).
Arguments
src,dest: paths to compare
Keyword arguments
size_only::Bool = false→ skip hash checkdownload::Bool = false→ download and compare byte-by-byteone_way::Bool = false→ only check that source files exist in destcheckfile::Union{Nothing,String} = nothing→ treat src as SUM file
Logging/reporting (like sync)
combined,differ,missing_on_dst,missing_on_src,error_log
Filtering & verbosity
exclude,include,verbose, etc.
Example
output = rclone_check("local:/data", "s3:backup", size_only=true, verbose=1)
println(output)RcloneInterface.rclone_copy — Methodrclone_copy(src::AbstractString, dest::AbstractString; kwargs...)Copy files from src to dest using rclone copy.
Arguments
src: Source path (e.g.,"local:/path"or"remote:bucket/dir")dest: Destination path
Keyword arguments (common flags)
dry_run::Bool = false: Do a trial run without copying (--dry-run)verbose::Int = 0: Verbosity level (-v,-vv, etc.)checksum::Bool = false: Use checksum + size to detect changes (-c)update::Bool = false: Skip files newer on destination (-u)ignore_existing::Bool = false: Skip files that already existmax_age::Union{Nothing, String} = nothing: Only copy files younger than this (e.g.,"24h")exclude::Vector{String} = String[]: Patterns to excludeinclude::Vector{String} = String[]: Patterns to includemetadata::Bool = false: Preserve metadata (-M)progress::Bool = false: Show progress (-P)extra_flags::Vector{String} = String[]: Additional raw flags
Example
rclone_copy("mylocal:/data", "gdrive:backup", dry_run=true, verbose=1)RcloneInterface.rclone_dedupe — Methodrclone_dedupe(path::AbstractString; kwargs...)Find and resolve duplicate files (by name or hash).
⚠️ Can delete or rename files. Use
dry_run=truefirst!
Arguments
path: remote path to dedupe
Keyword arguments
by_hash::Bool = false→ dedupe by content hash instead of namededupe_mode::String = "interactive"→"skip","first","newest","rename", etc.size_only::Bool = false→ use size only (for backends without hash)dry_run::Bool = falseinteractive::Bool = falseverbose::Int = 0
Example
rclone_dedupe("gdrive:photos", dedupe_mode="rename", dry_run=true)
rclone_dedupe("crypt:backups", by_hash=true, dedupe_mode="largest")RcloneInterface.rclone_delete — Methodrclone_delete(path::AbstractString; kwargs...)Delete files in the given path, respecting filters. Does not delete directories unless rmdirs=true is used.
⚠️ Warning: This permanently deletes data. Always test with
dry_run=true.
Arguments
path: Remote or local path to delete from
Keyword arguments
dry_run::Bool = falseinteractive::Bool = falsermdirs::Bool = false→ also remove empty directoriesverbose::Int = 0
Filtering (same as other commands)
exclude,include,max_age,min_size, etc.
Example
rclone_delete("gdrive:temp", dry_run=true, max_size="1G")
rclone_delete("s3:bucket/logs", rmdirs=true, min_age="7d")RcloneInterface.rclone_exe — Methodrclone_exe(cmd::Cmd; collect = true)Execute rclone with the given Cmd.
RcloneInterface.rclone_exe — Methodrclone_exe(args::AbstractString...; collect = true)Execute rclone with the given arguments. Returns stdout/stderr as a string if collect=true (default).
RcloneInterface.rclone_help — Methodrclone_help(; topic::Union{Nothing, String} = nothing)Show general help or help for a specific command/topic.
Returns help text as a string.
Arguments
topic: e.g.,"sync","mount", or a backend name like"s3"
Example
general = rclone_help()
sync_help = rclone_help(topic="sync")RcloneInterface.rclone_ls — Methodrclone_ls(path::AbstractString; kwargs...)List files in the given path with size and path (like rclone ls).
Returns a string with one line per file: <size> <path>
Arguments
path: Remote or local path to list
Keyword arguments
max_depth::Int = -1→--max-depth N(default: recurse fully)recursive::Bool = true→ controls recursion (note:lsrecurses by default)exclude::Vector{String} = String[]include::Vector{String} = String[]max_age,min_age,max_size,min_sizefiles_only::Bool = true(default behavior)dirs_only::Bool = falsefast_list::Bool = false→--fast-listverbose::Int = 0extra_flags::Vector{String} = String[]
Note:
rclone lsrecurses by default. Usemax_depth=1to list only top level.
```
RcloneInterface.rclone_move — Methodrclone_move(src::AbstractString, dest::AbstractString; kwargs...)Move files from source to destination. After a successful move, files are deleted from the source.
⚠️ Warning: This can cause data loss. Always test with
dry_run=true.
Arguments
src: Source pathdest: Destination path
Keyword arguments
Safety & testing
dry_run::Bool = falseinteractive::Bool = false
Behavior
checksum::Bool = falseupdate::Bool = falseignore_existing::Bool = falsesize_only::Bool = falseignore_times::Bool = falsemetadata::Bool = false
Source cleanup
delete_empty_src_dirs::Bool = false→--delete-empty-src-dirscreate_empty_src_dirs::Bool = false→--create-empty-src-dirs
Filtering
max_age,min_age,max_size,min_sizeexclude::Vector{String} = String[]include::Vector{String} = String[]no_traverse::Bool = false
Output & control
verbose::Int = 0progress::Bool = falseextra_flags::Vector{String} = String[]
Example
rclone_move("local:/tmp/old", "archive:old", dry_run=true)
rclone_move("s3:bucket/temp", "gcs:archive", delete_empty_src_dirs=true, checksum=true)RcloneInterface.rclone_size — Methodrclone_size(path::AbstractString; kwargs...)Print the total size and number of objects in path.
Returns a string with human-readable summary (e.g., "Total objects: 123, Total size: 4.5 GiB").
Keyword arguments
max_depth::Int = -1→ limit recursion depthexclude::Vector{String} = String[]include::Vector{String} = String[]max_age,min_age,max_size,min_sizefast_list::Bool = falsejson::Bool = false→ return JSON-formatted output insteadextra_flags::Vector{String} = String[]
Example
summary = rclone_size("gdrive:photos")
json_out = rclone_size("s3:bucket", json=true)RcloneInterface.rclone_sync — Methodrclone_sync(src::AbstractString, dest::AbstractString; kwargs...)Synchronize the source to the destination, making the destination identical to the source. This may delete files in the destination that are not present in the source.
⚠️ Warning: This command can cause data loss. Always test with
dry_run=true.
Arguments
src: Source path (e.g.,"local:/data"or"remote:bucket/dir")dest: Destination path
Keyword arguments (common & sync-specific flags)
Safety & Testing
dry_run::Bool = false→--dry-runinteractive::Bool = false→--interactive(-i)
Core behavior
checksum::Bool = false→-c, use checksum + sizeupdate::Bool = false→-u, skip files newer on destinationignore_existing::Bool = false→ skip files that already existsize_only::Bool = false→ skip based on size onlyignore_times::Bool = false→-I, transfer all unconditionallymetadata::Bool = false→-M, preserve metadata
Deletion control
max_delete::Int = -1→--max-delete N(default: unlimited)delete_excluded::Bool = false→--delete-excludedignore_errors::Bool = false→ delete even if I/O errors occur
Performance & filtering
no_traverse::Bool = false→--no-traversemax_age::Union{Nothing,String} = nothingmin_age::Union{Nothing,String} = nothingmax_size::Union{Nothing,String} = nothingmin_size::Union{Nothing,String} = nothingexclude::Vector{String} = String[]include::Vector{String} = String[]
Logging & reporting (output to file or stdout)
combined::Union{Nothing,String} = nothing→--combined FILEdiffer::Union{Nothing,String} = nothing→--differ FILEmissing_on_dst::Union{Nothing,String} = nothingmissing_on_src::Union{Nothing,String} = nothingerror_log::Union{Nothing,String} = nothing→--error FILE
Other
verbose::Int = 0→-v,-vv, etc.progress::Bool = false→-Pcreate_empty_src_dirs::Bool = falsetrack_renames::Bool = false→ enable rename detectionextra_flags::Vector{String} = String[]
Example
rclone_sync("local:/photos", "gdrive:backup/photos", dry_run=true, verbose=1)
rclone_sync("s3:mybucket", "b2:archive", max_delete=100, checksum=true)RcloneInterface.rclone_tree — Methodrclone_tree(path::AbstractString; kwargs...)Print a directory tree of the remote path.
Returns a string showing the hierarchical structure.
Keyword arguments
max_depth::Int = -1dirs_only::Bool = falsefiles_only::Bool = falseexclude,include,max_age, etc. (same as other commands)extra_flags::Vector{String} = String[]
Example
tree = rclone_tree("dropbox:projects", max_depth=2)
println(tree)RcloneInterface.rclone_version — Methodrclone_version(; check::Bool = false, deps::Bool = false)Return the rclone version info as a string.
Keyword arguments
check::Bool = false→ compare with latest release/beta onlinedeps::Bool = false→ show Go dependencies
Example
println(rclone_version())
println(rclone_version(check=true))