Install the Latch CLI:
Next, authenticate your account. This can be done one of two ways:
latch login
which will authenticate you through the browser that you’re logged into.By default, LatchCLI references your personal workspace. To switch workspaces, use the command:
Verifiy the authentication works
Upload files from local machine to Latch Data:
file.txt
and puts it into welcome/
on Latch.Download files from Latch Data to local machine:
/welcome
on Latch and puts them into local_folder
on your local computer.Copy files between two Latch Data paths in the same workspace:
/dir1
on Latch and puts them into /dir2
on Latch.Copy Latch Data files between two different workspace:
/dir1
in workspace 123 and puts them into /dir2
in workspace 456.file.txt
in dir2
and remove it from dir1
in your current workspace.
dir1
in Latch Data with the contents of local_folder
on your local computer.
local_folder
and rerun the above command, the changes will be reflected in dir1
in Latch Data. The sync
command will only upload files when:
sync
command will not remove files from the remote directory if they are removed from local_folder
on your local computer. To allow files to be deleted from the remote directory, use the --delete
flag:
dir1
:
dir3
, creating parent directories dir1
and dir2
if they do not exist:
dir2
in Latch Data:
local_directory
to latch_folder
:
latch_folder
:
latch cp local_directory/ latch:///latch_folder
.
latch --version
.
latch rm
- Use latch rmr
insteadlatch mkdir
- Use latch mkdirp
insteadlatch touch
- No longer supportedlatch open
- No longer supported