No description
Find a file
Gunwant Jain 27f84bbe3b add readme
Needs a hosting guide too.

Signed-off-by: Gunwant Jain <mail@wantguns.dev>
2020-12-30 04:37:30 +05:30
src add readme 2020-12-30 04:37:30 +05:30
templates fix MIME types and add examples 2020-12-29 21:37:54 +05:30
.gitignore add /p/<id> routes 2020-12-29 17:37:29 +05:30
Cargo.lock add /p/<id> routes 2020-12-29 17:37:29 +05:30
Cargo.toml index: improve the usage guide 2020-12-30 03:41:54 +05:30
docker-compose.yml Dockerised the app 2020-12-30 04:20:39 +05:30
Dockerfile Dockerised the app 2020-12-30 04:20:39 +05:30
readme add readme 2020-12-30 04:37:30 +05:30

    USAGE
    -----

        POST    / 

            accepts raw data in the body of the request and responds with a URL
            of a page containing the body's content

        GET     /<id>

            retrieves the content for the paste with id `<id>`

        GET     /p/<id>

            retrieves the HTML page with syntax-highlighted content for the paste with id `<id>`
 
    EXAMPLES
    --------

        Paste a file named 'file.txt' using cURL:

            curl -d@file.txt https://bin.wantguns.dev

        Paste from stdin using cURL:

            echo "Hello, world." | curl -d@- https://bin.wantguns.dev

        Add this to your .zshrc to implement a quicker usage.

            function paste() {
              local file=${1:-/dev/stdin}
              curl -d@${file} https://bin.wantguns.dev
            }

        If the uploaded data binary is parsed as "text/*", then the paste will be syntax
        highlighted