GPM is a command-line tool written in Go that helps to manage processes on your server or local machine. It consists of two modules - gpm.exe
which runs as a daemon in the background, and gpm-cli
which provides a command-line interface for managing processes. With GPM, you can start, stop, restart, and monitor processes on your system.
- Go 1.16 or higher installed on your system.
-
Clone the repository from GitHub:
git clone https://github.com/Vulnware/GPM.git
-
Build the binary for
gpm.exe
using the following command: For windows:make.bat
For linux:
make
-
Build the binary for
gpm-cli
using the following command: For windows:cd cli make.bat
For linux:
cd cli make
-
Move both binaries to the
/usr/local/bin
directory so that they can be executed from anywhere in the terminal for linux orC:\Windows
for windows (or any other directory that is in yourPATH
environment variable). You can also add the directory where the binaries are located to yourPATH
environment variable. For linux:mv gpm.exe /usr/local/bin mv gpm-cli /usr/local/bin
For windows:
mv gpm.exe C:\Windows mv gpm-cli C:\Windows
Or add the directory where the binaries are located to your
PATH
environment variable. -
Verify that GPM is installed correctly by running the following command:
gpm-cli --version
You should see the version number of GPM printed to the console.
To start a process with GPM, run the following command:
gpm-cli start <command> <args>
For example, to start a Node.js server with GPM, you could use the following command:
gpm-cli start "node server.js" --name "node-server"
To stop a process with GPM, run the following command:
gpm-cli stop <process-name>
For example, to stop the Node.js server that we started earlier, you could use the following command:
gpm-cli stop node-server
To restart a process with GPM, run the following command:
gpm-cli restart <process-name>
For example, to restart the Node.js server that we started earlier, you could use the following command:
gpm-cli restart node-server
To list all the processes that are currently running with GPM, run the following command:
gpm-cli ls
To view the logs for a process that is running with GPM, run the following command:
gpm-cli logs <process-name>
For example, to view the logs for the Node.js server that we started earlier, you could use the following command:
gpm-cli logs node-server
If you would like to contribute to GPM, please open a pull request on GitHub. We welcome any contributions, including bug fixes, new features, and documentation improvements.
GPM is licensed under the MIT license. See the LICENSE
file for more information.