CmdUtils.CreateCommand({
  name: "unwrap",
  homepage: "http://metapundit.net/",
  author: {name: "Simeon Franklin", email: "sf@simeonfranklin.com"},
  license: "GPL",
  description: "Removes newlines from selected editable text",
  help: "Highlight text in a textarea, unwrap",
  takes: {"input": /.*/},
  preview: function(pblock, input) {
    pblock.innerHTML = "Removing newlines from selected " + input.text;
  },
  execute: function(input) {
    re = /\n/g;
    CmdUtils.setSelection(input.text.replace(re, ''));
  }
});
