cjdns-admin v0.2.0 release

There is a new release of the cjdns-admin module for node.

https://github.com/tcrowe/cjdns-admin
https://www.npmjs.com/package/cjdns-admin

Updates include:

  • refactor including jslint
  • remove unwanted console.log
  • change constructor API
  • new members which return all pages at once

Thanks go to cel and willeponk for feedback and ideas.

Install:

npm install cjdns-admin@0.2.0

Example of constructor change:

var cjdnsAdmin = require('cjdns-admin'),
    admin;

admin = cjdnsAdmin.createAdmin({
    host: process.env.CJDNS_ADMIN_IP,
    port: process.env.CJDNS_ADMIN_PORT,
    password: process.env.CJDNS_ADMIN_PASSWORD
});

If you had your admin credentials on your environment that would work.

Get all nodes at once:

admin.nodeStore.dumpTablePaged(function (err, results) {
    if (err) return console.log('paged result fail', err);
    console.log('all nodes', results);
});

Enjoy all that juicy data!

<3

Author Tony Crowe, Salt Lake City, UT
top
home
Attribution
Lato font by Ɓukasz Dziedzicwww.latofonts.com/team
Roboto font by Christian Robertson, Google Incchristianrobertson.comwww.google.com/fonts
Inconsolata font by Raph Levien, Google Incwww.levien.comwww.google.com/fonts
hexo: fast, simple & powerful blog frameworkhexo.io
ace editorace.c9.io
virtual-domwww.npmjs.com/package/virtual-dom
Black Granite Water Droplets, William Warbyhttps://www.flickr.com/photos/wwarby