-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
46 lines (32 loc) · 1.55 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<title>curl-paste.local - Golang Powered Curl Pastebin</title>
<meta name="author" content="Vinu K">
<meta name="description" content="curl-paste.local is a simple
CLI curl pastebin service powered by Golang">
<link href="http://curl-paste.local/" rel="canonical">
</head>
<body data-new-gr-c-s-check-loaded="8.904.0" data-gr-ext-installed=""><pre> BROWSER USAGE
<a href="http://curl-paste.local" alt="curl-paste.local web page">http://curl-paste.local/</a>
API USAGE
POST http://curl-paste.local/
Send the form data along. Will respond with a link to the paste.
GET https://curl-paste.local/<id>
Retrieve the paste with the given id as plain-text.
EXAMPLES
Paste a file named 'file.txt' using cURL:
curl -F 'title=Request from cURL' -F 'paste=<file.txt' http://curl-paste.local/
Paste from stdin using cURL:
echo "Hello, world." | curl -F 'title=Request from cURL' -F 'paste=<-' http://curl-paste.local/
A shell function that can be added to `.bashrc` or `.bash_profle` for
quick pasting from the command line. The command takes reads from stdin
if none was supplied and outputs the URL of the paste to stdout:
`echo "hi" | curl-paste`.
function curl-paste() {
curl -F 'title=Request from cURL' -F 'paste=<-' https://curl-paste.local
}
</pre>
</body>
</html>