FB(1)

NAME
fb - a shell-script client for http://paste.xinu.at

SYNOPSIS
fb [options] file/directory ...
fb [-dg] [options] ID/URL ...
fb [-hv]

DESCRIPTION
fb is a client to http://paste.xinu.at which allows the user to easily upload, delete or download files. By default, files will be uploaded as-is and a link to the file will be printed to stdout after each upload.

Directories will be packed into a tarball with tar(1) and the resulting upload.tar file will be uploaded. If no arguments are given, data will be read from stdin into a temporary file that will be uploaded as soon as EOF is received. If the file being uploaded is bigger than 10MB fb will query the server for the maximum upload size and abort the upload if the file would be rejected. Before terminating, fb will try to copy all links into the X clipboard if xclip(1) is installed.

If you want to use paste.xinu.at, you need to create an account there and add the following to your ~/.netrc:

    machine paste.xinu.at
      login <your_username> password <your_secret_password>

OPTIONS

-c  Compress the files to be uploaded using gzip(1). This affects all files including piped content and directories. If specified twice, xz(1) will be used rather than gzip. If used in conjunction with the -g option this decompresses the download before it's output to stdout.

-d  Delete the IDs. You can no longer upload files in this mode. If the argument is a URL, fb will try to extract the ID.

-e extension
    Change the extension used for highlighting. You can also do this if you have already uploaded the file by appending the extension to the URL. http://paste.xinu.at/<ID>/bash will change the syntax highlighting to bash.

-n file name
    Use the specified file name for the upload when pasting from stdin. Defaults to "stdin"

-a  Create a new api key.

-H  Display a history of uploads.

-g  Download the IDs and output on stdout. Please take care when using this, as binary data may cause unexpected results when being output directly to a terminal. You can no longer upload files in this mode. If the argument is a URL, fb will try to extract the ID.

-h  Display a short help message.

-t  Upload a tar file containing all files and directories specified on the command line.

-v  Display the client version.

-D  Display debugging information.

CONFIGURATION FILES

$XDG_CONFIG_HOME/fb-client/apikey
    This file contains the API key to use for authentication. If this file exists, netrc authentication will be disabled.

$XDG_CONFIG_HOME/fb-client/config
    This file allows to override certain variables by using the format 'option_name="value"'. Both, the option value and name, are case-sensitive string literals.

    The following option names are supported:

    pastebin
        The URL of the pastebin you want to use

    clipboard_cmd
        The command used to copy URLs of uploaded files to the clipboard. This defaults to xclip or pbcopy on Darwin.

    apikey_file
        The file that contains the API key. This defaults to "$XDG_CONFIG_HOME/fb-client/apikey"

~/.netrc
    This file will be used for authentication.

ENVIRONMENT
Some options can be changed by modifying environment variables:

GZIP
    Assigning GZIP will make the gzip-program treat it's value as if they had been appended to the command line.

XZ_OPTS
    The XZ_OPTS environment variable can be used in order to pass additional options to xz, in case xz is used for compression.

TMPDIR
    Setting TMPDIR to some directory where fb create temporary files inside this directory rather than /tmp, if the underlying mktemp(1) program supports it.

EXAMPLES

fb -tc directory file
    This will create a .tar archive containing the directory and the file and compress it using gzip and upload one archive.

fb -c directory file
    This will create a .tar archive containing only the directory. Both (directory and file) will be compressed using gzip and uploaded independently.

fb -cc directory
    This will create a .tar archive containing only the directory and compress it using xz.

make |& fb
    This will upload the output of make (stdout and stderr) in csh and similar shells.

SEE ALSO
curl(1), gzip(1), mktemp(1), tar(1), xz(1), xclip(1)

AUTHORS
-nosplit fb was written by
•   Florian Pritz <bluewind@xinu.at>
•   Moritz Wilhelmy <moritz@wzff.de>
and may be copied under the terms of the GPLv3.