|
| 1 | +# 🚀 Process Manager (PM) |
| 2 | + |
| 3 | +A high-performance, modular process management suite for Linux, featuring both a powerful command-line interface and a modern GTK3-based graphical user interface. |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | + |
| 9 | + |
| 10 | +## ✨ Features |
| 11 | + |
| 12 | +- **📊 Real-time Monitoring:** Advanced task manager for tracking system processes. |
| 13 | +- **🛠️ Job Control:** Full support for foreground (`fg`) and background (`bg`) job management. |
| 14 | +- **📡 Signal Handling:** Seamlessly send signals (SIGKILL, SIGSTOP, SIGCONT) to manage process states. |
| 15 | +- **💻 Integrated Shell:** Custom shell mode for executing external commands and scripts. |
| 16 | +- **🎨 Hybrid Interface:** Choose between a sleek CLI (`pm_shell`) or a native GTK3 GUI (`pm_gui`). |
| 17 | + |
| 18 | +--- |
| 19 | + |
| 20 | +## 🛠️ Installation & Build |
| 21 | + |
| 22 | +### Prerequisites |
| 23 | +Ensure you have the following installed on your Linux system: |
| 24 | +- `gcc` (GNU Compiler Collection) |
| 25 | +- `make` |
| 26 | +- `libgtk-3-dev` (for the GUI version) |
| 27 | + |
| 28 | +### Building the Project |
| 29 | +Clone the repository and run the provided Makefile: |
| 30 | + |
| 31 | +```bash |
| 32 | +git clone https://github.com/yourusername/process-manager.git |
| 33 | +cd process-manager |
| 34 | +make all |
| 35 | +``` |
| 36 | + |
| 37 | +This will generate two binaries: |
| 38 | +- `pm_shell`: The interactive CLI version. |
| 39 | +- `pm_gui`: The graphical GTK3 version. |
| 40 | + |
| 41 | +--- |
| 42 | + |
| 43 | +## 🚀 Usage |
| 44 | + |
| 45 | +### Command Line Interface |
| 46 | +Launch the shell version for a classic terminal experience: |
| 47 | +```bash |
| 48 | +./pm_shell |
| 49 | +``` |
| 50 | +**Menu Options:** |
| 51 | +1. **Monitor Processes:** View active processes. |
| 52 | +2. **Job Management:** Switch between foreground and background jobs. |
| 53 | +3. **Process Control:** Send signals to PIDs. |
| 54 | +4. **PM Shell Mode:** Use it as a functional system shell. |
| 55 | + |
| 56 | +### Graphical User Interface |
| 57 | +Launch the GUI for a more visual experience: |
| 58 | +```bash |
| 59 | +./pm_gui |
| 60 | +``` |
| 61 | +The GUI provides a clean, list-based view of processes with interactive controls powered by GTK3. |
| 62 | + |
| 63 | +--- |
| 64 | + |
| 65 | +## 📂 Project Structure |
| 66 | + |
| 67 | +| File | Description | |
| 68 | +| :--- | :--- | |
| 69 | +| `main.c` | Entry point for the CLI application. | |
| 70 | +| `gui_main.c` | Entry point and layout for the GTK3 GUI. | |
| 71 | +| `process_mgmt.c` | Core logic for process execution and monitoring. | |
| 72 | +| `job_control.c` | Handles foreground/background job states. | |
| 73 | +| `signals.c` | Manages UNIX signal handling and process communication. | |
| 74 | +| `utils.c` | Shared helper functions and formatting. | |
| 75 | + |
| 76 | +--- |
| 77 | + |
| 78 | +## 📜 License |
| 79 | +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. |
| 80 | + |
| 81 | +## 🤝 Contributing |
| 82 | +Contributions are welcome! Please feel free to submit a Pull Request. |
0 commit comments