{"id":23,"date":"2005-08-31T00:15:50","date_gmt":"2005-08-30T23:15:50","guid":{"rendered":"https:\/\/raphael.slinckx.net\/blog\/?p=23"},"modified":"2006-06-19T22:41:39","modified_gmt":"2006-06-19T20:41:39","slug":"the-wonders-of-pastebin","status":"publish","type":"post","link":"https:\/\/raphael.slinckx.net\/blog\/2005-08-31\/the-wonders-of-pastebin","title":{"rendered":"The wonders of pastebin"},"content":{"rendered":"<p>These last days, i&#8217; ve been using pastebin intensively, for things like diffs reviews, code snippets to discuss, etc.<\/p>\n<p>And i got sick of the web interface.<\/p>\n<p>So i took a couple of hours to write this nice python script which allows to upload seamlessly any content to <a href=\"http:\/\/en.pastebin.ca\/\">pastebin.ca<\/a>, and maybe it will be useful for other people than me, so i <a href=\"https:\/\/raphael.slinckx.net\/files\/pastebin\">publish it here<\/a>.<\/p>\n<p>Very simple to use here is the usage():<\/p>\n<pre>\r\n$ pastebin [OPTIONS] [FILE]\r\n\r\nPrint the pastebin.ca URL of the input file\r\n\r\nIf FILE is omitted content is read from standard input\r\nOPTIONS:\r\n        -h, --help                      Print this help notice.\r\n        -r, --raw                       Retreive raw text URL (default=off).\r\n        -d, --description       The description of the content (default=empty).\r\n        -m, --message           Same as description\r\n        -n, --name                      Your name (default=your unix username).\r\n        -t, --type                      The type of the content (default=\"raw\")\r\n\r\n        Type can be one of:\r\n        raw, asterisk, c, cpp, php, perl, java, vb, csharp,\r\n        ruby, python, pascal, mirc, pli, xml, sql, scheme,\r\n        ascript, ada, apache, nasm, asp, bash, css, delphi, html, js,\r\n        lisp, lua, asm, objc, vbnet\r\n\r\n        If type is not specified, an attempt to auto-detect type is made,\r\n        based on file data\/extension. Detection is more reliable when giving FILE\r\n        argument than piping directly. This needs modules gnomevfs and gtksourceview\r\n\r\n        If you have module gtk, the pastebin url will be placed in your clipboard,\r\n        you can then paste it with ctrl-v as usual.\r\n<\/pre>\n<p>That means you can <code>cat important-patch.diff|pastebin -m 'look!'<\/code> then Ctrl-v in xchat or wherever the output URL.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>These last days, i&#8217; ve been using pastebin intensively, for things like diffs reviews, code snippets to discuss, etc. And i got sick of the web interface. So i took a couple of hours to write this nice python script which allows to upload seamlessly any content to pastebin.ca, and maybe it will be useful [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,2],"tags":[],"class_list":["post-23","post","type-post","status-publish","format-standard","hentry","category-planet-gnome","category-software"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/posts\/23","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/comments?post=23"}],"version-history":[{"count":0,"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/posts\/23\/revisions"}],"wp:attachment":[{"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/media?parent=23"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/categories?post=23"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/raphael.slinckx.net\/blog\/wp-json\/wp\/v2\/tags?post=23"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}