
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
i3-status-node
Advanced tools
A simple NodeJS status bar for i3wm that supports colour.
npm install -g i3-status-node
Create a .i3-status-node folder in your home folder.
This folder must contain a file named config.json which describes the layout of your status bar
and script files that produce the output for each section of the status bar.
// ~/.i3-status-node/config.json
{
'separator_width': 15,
'layout': [ 'kernel', 'diskusage' ]
}
A simple script that would display the kernel version would look like the following
// ~/.i3-status-node/kernel.js
var cp = require("child_process"),
exec = (cmd) => cp.execSync(cmd).toString().replace("\n", "");
module.exports = (update) => {
update(exec("uname -r"));
};
The update function can be called with either a string or an object representing a i3bar IPC message block. Using the IPC format allows for advanced usage such as printing in colour or suppressing the separator.
// ~/.i3-status-node/diskusage.js
var cp = require("child_process"),
exec = (cmd) => cp.execSync(cmd).toString().replace("\n", "");
module.exports = (update) => {
var updateTime = () => {
var diskUsedStr = exec("df -hPl / | awk 'NR==2{print $5}'");
var diskUsedPct = parseInt(diskUsedStr.substring(0, diskUsedStr.length - 1), 10);
update({
'full_text': diskUsedStr,
'color': (diskUsedPct > 90) ? '#ff0000' : '#00ff00'
});
setTimeout(updateTime, 60 * 1000);
}
updateTime();
};
The update callback will also accept arrays containing multiple messages in a mixture of either format. More example scripts can be found in the scripts folder.
In the i3 config file change the status_command setting to i3-status-node like so:
// ~/.config/i3/config
...
bar {
status_command i3-status-node
}
...
FAQs
A simple NodeJS status bar for i3wm that supports colour.
We found that i3-status-node demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.