0.0.1 • Published 11 years ago
pmux v0.0.1
pmux
pmux is a programmable multiplexer that takes either a JSON file or a node.js script that describes a series of commands to be executed in windows in a tmux session.
Getting Started
Install pmux with:
npm install -g pmuxExecute pmux with:
pmux <path-to-configuration-file>Example
basic_pmux_configuration.json:
{
"name": "simple_example",
"pre_commands": ["ls"],
"windows": {
"pwd": {
"commands": ["pwd"],
"dir" : "."
}
}
}Calling pmux examples/basic_pmux_configuration.json will:
- executes the
pre_commandssynchronously, so calllsto list the current directories content - creates a tmux session called
simple_example, destroying any other session with that name - creates a window in the
simple_examplesession called "pwd", starting in the directory.and then executing the commands in thecommandsarray.
The node.js script version of this file basic_pmux_configuration.js is:
module.exports = {
"name": "simple_example",
"pre_commands": ["ls"],
"windows": {
"pwd": {
"commands": ["pwd"],
"dir" : "."
}
}
}0.0.1
11 years ago