PBinCLI is command line client for [PrivateBin](https://github.com/PrivateBin/PrivateBin/) written on Python 3.
PBinCLI is command line client for [PrivateBin](https://github.com/PrivateBin/PrivateBin/) written on Python 3.
Installing
# Installing
=====
Installation inside `virtualenv`:
Installation inside `virtualenv`:
```bash
```bash
@ -24,8 +22,7 @@ pip3 install pbincli
*Note*: if you used installation with `virtualenv`, don't forget to activate it before usage: call `. /path/to/venv/bin/activate` in terminal
*Note*: if you used installation with `virtualenv`, don't forget to activate it before usage: call `. /path/to/venv/bin/activate` in terminal
Configuration
# Configuration
=====
By default pbincli configured to use `https://paste.i2pd.xyz/` for sending and receiving pastes. No proxy used by default.
By default pbincli configured to use `https://paste.i2pd.xyz/` for sending and receiving pastes. No proxy used by default.
@ -33,41 +30,42 @@ You can create config file to use different settings.
Configuration file is searched in `~/.config/pbincli/pbincli.conf`, `%APPDATA%/pbincli/pbincli.conf` (Windows) and `~/Library/Application Support/pbincli/pbincli.conf` (MacOS)
Configuration file is searched in `~/.config/pbincli/pbincli.conf`, `%APPDATA%/pbincli/pbincli.conf` (Windows) and `~/Library/Application Support/pbincli/pbincli.conf` (MacOS)
*Note*: It is possible to set-up paste parameters such as burning after reading, expiritaion time, formatting, enabling discussions, and changing compression algorithm. Please refer to `pbincli send -h` output for more information.
### Other options
Receiving
It is possible to set-up paste parameters such as burning after reading, expiritaion time, formatting, enabling discussions, and changing compression algorithm. Please refer to `pbincli send -h` output for more information.
-----
## Receiving
To retrieve paste from server, use `get` command with paste info.
To retrieve paste from server, use `get` command with paste info.
@ -104,8 +103,7 @@ pbincli get xxx#yyy ### receive paste xxx from https://pa
pbincli get https://example.com/?xxx#yyy ### receive paste xxx from https://example.com/
pbincli get https://example.com/?xxx#yyy ### receive paste xxx from https://example.com/
```
```
Deletion
## Deletion
-----
To delete paste from server, use `delete` command with required `-p` and `-t` options:
To delete paste from server, use `delete` command with required `-p` and `-t` options:
If you need to delete paste on different server that configured, use `-s` option with instance URL.
If you need to delete paste on different server that configured, use `-s` option with instance URL.
Additional examples
# Additional examples
=====
Here you can find additional examples.
Here you can find additional examples.
Usage with service available inside I2P
## Usage with service available inside I2P
-----
Change settings to use server `http://privatebin.i2p/` and proxy `http://127.0.0.1:4444`. Here's example for configuration file:
Change settings to use server `http://privatebin.i2p/` and proxy `http://127.0.0.1:4444`. Here's example for configuration file:
```ini
```ini
@ -128,8 +124,7 @@ server=http://privatebin.i2p/
proxy=http://127.0.0.1:4444
proxy=http://127.0.0.1:4444
```
```
Using tool with aliases
## Using tool with aliases
-----
Example of alias to send paste from `stdin` direclty to I2P service:
Example of alias to send paste from `stdin` direclty to I2P service:
```bash
```bash
@ -138,7 +133,6 @@ alias pastei2p="echo 'paste the text to stdin' && pbincli send -s http://private
Call it by running `pastei2p` in terminal.
Call it by running `pastei2p` in terminal.
License
# License
=====
This project is licensed under the MIT license, which can be found in the file [LICENSE](https://github.com/r4sas/PBinCLI/blob/master/LICENSE) in the root of the project source code.
This project is licensed under the MIT license, which can be found in the file [LICENSE](https://github.com/r4sas/PBinCLI/blob/master/LICENSE) in the root of the project source code.
- Domain name of shortener service for ``yourls``\ , or sortener URL (with required parameters) for ``custom``
- Domain name of shortener service for ``yourls``\ , or URL (with required parameters) for ``custom``
* - short_user
* - short_user
- None
- None
- Used only in ``yourls``
- Used only in ``yourls``
@ -98,6 +110,9 @@ All possible options for configuration file
* - no_insecure_warning
* - no_insecure_warning
- False
- False
- True / False
- True / False
* - compression
- zlib
- zlib / none
Usage
Usage
@ -143,7 +158,10 @@ Sending
pbincli send -q -f info.pdf
pbincli send -q -f info.pdf
*Note*\ : It is possible to set-up paste parameters such as burning after reading, expiritaion time, formatting, enabling discussions, and changing compression algorithm. Please refer to ``pbincli send -h`` output for more information.
Other options
^^^^^^^^^^^^^
It is possible to set-up paste parameters such as burning after reading, expiritaion time, formatting, enabling discussions, and changing compression algorithm. Please refer to ``pbincli send -h`` output for more information.