vtop
Advanced tools
Comparing version 0.1.1 to 0.1.2
13
app.js
@@ -5,3 +5,3 @@ /** | ||
* http://parall.ax/vtop | ||
* | ||
* | ||
* Because `top` just ain't cutting it anymore. | ||
@@ -20,4 +20,8 @@ * | ||
program = blessed.program(), | ||
os = require("os"); | ||
os = require('os'), | ||
cli = require('commander'); | ||
// Set up the commander instance and add the required options | ||
cli.option('-t, --theme [name]', 'set the vtop theme [parallax|brew|wizard]', 'parallax').parse(process.argv); | ||
/** | ||
@@ -253,3 +257,5 @@ * Instance of blessed screen, and the charts object | ||
init: function() { | ||
loadedTheme = require('./themes/parallax.json'); | ||
// Get the theme, it defaults to parallax | ||
var theme = cli.theme; | ||
loadedTheme = require('./themes/' + theme + '.json'); | ||
@@ -302,3 +308,2 @@ // Create a screen object. | ||
processList = blessed.box({ | ||
@@ -305,0 +310,0 @@ top: graph.height + 1, |
{ | ||
"name": "vtop", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"description": "Wow such top. So stats", | ||
@@ -27,4 +27,5 @@ "main": "run.js", | ||
"read": "1.0.5", | ||
"blessed": "0.0.33" | ||
"blessed": "0.0.33", | ||
"commander": "2.2.0" | ||
} | ||
} |
@@ -1,5 +0,64 @@ | ||
Velocity | ||
vtop | ||
========= | ||
Simply show some well fit stats. | ||
A graphical activity monitor for the command line. Written in node.js. | ||
![](docs/example.gif) | ||
How to install | ||
--- | ||
If you haven't already got Node.js, then [go get it](http://nodejs.org/). | ||
``` | ||
npm install -g vtop | ||
``` | ||
Running | ||
--- | ||
This is pretty simple too. | ||
``` | ||
vtop | ||
``` | ||
FAQs | ||
---- | ||
### How does it work? | ||
It uses Unicode braille characters to draw CPU and Memory charts, helping you visualize spikes. We also group processes with the same name together. | ||
### I think the CPU % is coming out wrong. | ||
We calculate the CPU percentage as a total of your overall system power. 100% is all cores and HyperThreads maxed out. This is different to how Apple Activity monitor works. | ||
### I think you should change CPU percentage to how Apple's Activity Monitor works. | ||
No I like it this way. Feel free to submit a PR with it as a config option though. | ||
### Can I change the color scheme? | ||
Sure, just do: | ||
``` | ||
vtop --theme wizard | ||
``` | ||
This loads the theme file in themes/ with the same name. Make your own and send me a Pull Request :) | ||
You could add this to your aliases if you'd like to use it always. | ||
``` | ||
alias vtop="vtop --theme brew" | ||
``` | ||
### What about measuring server req/s, log entries, etc etc? | ||
Yeah that's on the list :) Feel free to send a pull request though. Check out the sensors/ folder. | ||
### What license is this under? | ||
MIT – do what you like with it :) | ||
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
1929165
15
576
65
5
3
+ Addedcommander@2.2.0
+ Addedcommander@2.2.0(transitive)