Skip to main content

cat

This command allows to get the contents of a BatchX file through stdout.

info

The cat command can be used with or without prepending bx:// to the path.

Usage

bx cat [--help] [-e=<end>] [-s=<start>] <path>

Parameters and inputs

ShorthandLong versionDescription
-s--startOffset (0-based) of the first byte to return (default: 0)
-e--endOffset of the last byte to return (exclusive) (default: file length)
--helpShow this help message and exit

Examples

Plain text file

Create a local file with the content "hello".

$ echo hello > hello.txt

Upload the file to BatchX using the bx cp command.

$ bx cp hello.txt bx://test/hello.txt
hello.txt [=================================================>] 100 %%

Print file content using the bx cat command.

$ bx cat bx://test/hello.txt
hello