Skip to content

Instantly share code, notes, and snippets.

@clehner
Forked from comboy/update.rb
Created November 28, 2012 03:24
Show Gist options
  • Save clehner/4158853 to your computer and use it in GitHub Desktop.
Save clehner/4158853 to your computer and use it in GitHub Desktop.
update all your namecoin domains
#!/usr/bin/env coffee
# put this file in the same dir as namecoind executable
child_process = require 'child_process'
child_process.exec './namecoind name_list', (err, stdout, stderr) ->
(JSON.parse stdout).forEach (domain) ->
if domain.expires_in < 5000
command = "./namecoind name_update #{JSON.stringify domain.name} #{JSON.stringify domain.value}"
child_process.exec command, () ->
console.log command
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment