Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

node-pastie

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-pastie

Wrapper to create pasties on http://pastie.org

  • 0.0.3
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
2
Maintainers
1
Weekly downloads
 
Created
Source

node-pastie

Wrapper to create new paste on http://pastie.org

Installation

npm install node-pastie

Usage

var pastie = require('node-pastie');

You can create a pastie with a string:

pastie.create("Any string can fit here", function(err, url) {
  console.log("Pastie url: "+url);
});

Or you can simply pass an object (that will be stringified)

pastie.create({message: "You can pass objects too!"}, function(err, url) {
  console.log("Pastie url: "+url);
});

Options

By default, it creates a private pastie, you can create a public pastie by passing the option {private: false}

pastie.create({message: "You can pass objects too!"}, { private: false }, function(err, url) {
  console.log("Pastie url: "+url);
});

Test

You can run the tests with mocha

Author

Xavier Damman (@xdamman)

FAQs

Package last updated on 22 Nov 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc