Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #2 from CoryG89/master

Remove util module dependency
  • Loading branch information...
commit 4e68c4c39310a1ebef7382aff395fdfa65e35e05 2 parents 8b2963c + 4bec6d4
@SchizoDuckie authored
Showing with 8 additions and 11 deletions.
  1. +1 −1  README.md
  2. +7 −10 node-cli.js
View
2  README.md
@@ -3,7 +3,7 @@ Node.CLI
By SchizoDuckie
-Updated By xkxx
+Updated By Cory Gross, xkxx
Super simple CLI cursor position control to spice up your script's functionality in terminal/console windows
Updated for 0.4.*
View
17 node-cli.js
@@ -1,20 +1,17 @@
/**
* Node.CLI
- * By SchizoDuckie
- * Updated By xkxx
+ * Original Author: SchizoDuckie
+ * Updated by: Cory Gross, xkxx
*
- * Super simple CLI cursor position control to spice up your script's functionality in terminal/console windows
- * Updated for 0.4.*
- * Requires util only
- * v2.0
+ * Super simple CLI for enhanced control over cursor position and color customization
+ * to spice up your script's functionality and appearance in terminal/console windows.
+ * Requires no dependencies. Instead utilizes Node.JS 'process' object to access stdout.
*
* ANSI escape codes are used. For details see: http://en.wikipedia.org/wiki/ANSI_escape_code
*
* Free to use and modify, enjoy!
*/
-var util = require("util");
-
function NodeCli () {
this.bold = true;
@@ -106,13 +103,13 @@ function NodeCli () {
//Output string @ current x/y
this.write = function(string) {
- util.print(string);
+ process.stdout.print(string);
return(this);
};
//Output string at new line
this.print = function(string) {
- util.puts(string);
+ process.stdout.puts(string);
return(this);
};
Please sign in to comment.
Something went wrong with that request. Please try again.