|
1 | 1 | use clap::{Parser, Subcommand}; |
2 | 2 | use colored::*; |
3 | | -use hacker::commands::{handle_run, handle_system, handle_unpack}; |
4 | | -use hacker::game::play_game; |
5 | | -use hacker::help::display_help; |
6 | | -use hacker::utils::{handle_update, run_command_with_spinner}; |
7 | | -use std::process::Command; |
| 3 | +use hacker::{display_help, handle_run, handle_system, handle_unpack, handle_update, play_game, run_command_with_spinner, RunCommands, SystemCommands, UnpackCommands}; |
8 | 4 |
|
9 | 5 | #[derive(Parser)] |
10 | 6 | #[command(name = "hacker", about = "A vibrant CLI tool for managing hacker tools, gaming, and system utilities", version = "1.0.0")] |
@@ -64,50 +60,6 @@ enum Commands { |
64 | 60 | Game, |
65 | 61 | } |
66 | 62 |
|
67 | | -#[derive(Subcommand)] |
68 | | -pub enum UnpackCommands { |
69 | | - /// Install add-ons (Wine, BoxBuddy, Winezgui, Gearlever) |
70 | | - AddOns, |
71 | | - /// Install both gaming and cybersecurity tools |
72 | | - GS, |
73 | | - /// Install development tools (Atom) |
74 | | - Devtools, |
75 | | - /// Install emulators (PlayStation, Nintendo, DOSBox, PS3) |
76 | | - Emulators, |
77 | | - /// Install cybersecurity tools (nmap, wireshark, Metasploit, Ghidra, etc.) |
78 | | - Cybersecurity, |
79 | | - /// Interactive UI for selecting individual packages |
80 | | - Select, |
81 | | - /// Install gaming tools (OBS Studio, Lutris, Steam, etc.) with Roblox |
82 | | - Gaming, |
83 | | - /// Install gaming tools without Roblox |
84 | | - Noroblox, |
85 | | - /// Install gamescope for hacker mode |
86 | | - HackerMode, |
87 | | -} |
88 | | - |
89 | | -#[derive(Subcommand)] |
90 | | -pub enum SystemCommands { |
91 | | - /// Show system logs |
92 | | - Logs, |
93 | | -} |
94 | | - |
95 | | -#[derive(Subcommand)] |
96 | | -pub enum RunCommands { |
97 | | - /// Run HackerOS Cockpit |
98 | | - HackerosCockpit, |
99 | | - /// Switch to another session |
100 | | - SwitchToOtherSession, |
101 | | - /// Update the system |
102 | | - UpdateSystem, |
103 | | - /// Check for system updates |
104 | | - CheckUpdates, |
105 | | - /// Launch Steam via HackerOS script |
106 | | - Steam, |
107 | | - /// Launch HackerOS Launcher |
108 | | - HackerLauncher, |
109 | | -} |
110 | | - |
111 | 63 | fn main() { |
112 | 64 | let cli = Cli::parse(); |
113 | 65 |
|
|
0 commit comments