shivexa-nova-terminal 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- shivexa_nova_terminal-0.1.0/PKG-INFO +77 -0
- shivexa_nova_terminal-0.1.0/Readme.md +69 -0
- shivexa_nova_terminal-0.1.0/pyproject.toml +23 -0
- shivexa_nova_terminal-0.1.0/setup.cfg +4 -0
- shivexa_nova_terminal-0.1.0/src/nova_terminal/__init__.py +0 -0
- shivexa_nova_terminal-0.1.0/src/nova_terminal/cli.py +10 -0
- shivexa_nova_terminal-0.1.0/src/nova_terminal/nova.py +474 -0
- shivexa_nova_terminal-0.1.0/src/shivexa_nova_terminal.egg-info/PKG-INFO +77 -0
- shivexa_nova_terminal-0.1.0/src/shivexa_nova_terminal.egg-info/SOURCES.txt +10 -0
- shivexa_nova_terminal-0.1.0/src/shivexa_nova_terminal.egg-info/dependency_links.txt +1 -0
- shivexa_nova_terminal-0.1.0/src/shivexa_nova_terminal.egg-info/entry_points.txt +2 -0
- shivexa_nova_terminal-0.1.0/src/shivexa_nova_terminal.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: shivexa-nova-terminal
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: NOVA Terminal for developers
|
|
5
|
+
Author: Shivexa
|
|
6
|
+
Requires-Python: >=3.10
|
|
7
|
+
Description-Content-Type: text/markdown
|
|
8
|
+
|
|
9
|
+
# ⚡ Shivexa NOVA Terminal
|
|
10
|
+
|
|
11
|
+
**A Developer-Focused Command-Line Terminal for Windows**
|
|
12
|
+
|
|
13
|
+
NOVA Terminal is a command-line tool developed by **Shivexa** to help developers execute commands, run programs, and manage development workflows from one place.
|
|
14
|
+
|
|
15
|
+
## ✨ Features
|
|
16
|
+
|
|
17
|
+
- 🐍 **Python Support** — Run Python programs and commands.
|
|
18
|
+
- 🟢 **Node.js Support** — Execute Node.js programs when Node.js is installed.
|
|
19
|
+
- 📦 **Package Management** — Work with `pip` and `npm` commands.
|
|
20
|
+
- 🎨 **Colorful Output** — Clear, color-coded terminal messages.
|
|
21
|
+
- ⚙️ **Command Execution** — Execute supported development commands.
|
|
22
|
+
- 💻 **Developer Friendly** — Designed for everyday development workflows.
|
|
23
|
+
|
|
24
|
+
## 📥 Installation
|
|
25
|
+
|
|
26
|
+
Install NOVA Terminal using pip:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
pip install shivexa-nova-terminal
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## 🚀 Start NOVA
|
|
33
|
+
|
|
34
|
+
After installation, run:
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
nova
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## 🛠️ Requirements
|
|
41
|
+
|
|
42
|
+
- Windows operating system is the primary target.
|
|
43
|
+
- Python 3.10 or later.
|
|
44
|
+
- Install Node.js separately if you want to use Node.js features.
|
|
45
|
+
- Some commands require their corresponding tools to be installed and available in PATH.
|
|
46
|
+
|
|
47
|
+
## 💡 Example Usage
|
|
48
|
+
|
|
49
|
+
Run NOVA:
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
nova
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Run a Python script using the supported command syntax in NOVA.
|
|
56
|
+
|
|
57
|
+
Install a Python package using the supported `pip` workflow.
|
|
58
|
+
|
|
59
|
+
Use Node.js commands when Node.js is installed.
|
|
60
|
+
|
|
61
|
+
*Available commands and syntax depend on the NOVA Terminal version.*
|
|
62
|
+
|
|
63
|
+
## 🔒 Security
|
|
64
|
+
|
|
65
|
+
Only execute commands and scripts you trust. Commands may modify files, install software, or change your system.
|
|
66
|
+
|
|
67
|
+
## 🏢 About Shivexa
|
|
68
|
+
|
|
69
|
+
NOVA Terminal is a developer-focused project by **Shivexa**, built to make command-line workflows more accessible and convenient.
|
|
70
|
+
|
|
71
|
+
## 📄 License
|
|
72
|
+
|
|
73
|
+
The license will be specified in a future release. Please check the project's repository for current licensing information.
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
**Developed with ❤️ by Shivexa**
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# ⚡ Shivexa NOVA Terminal
|
|
2
|
+
|
|
3
|
+
**A Developer-Focused Command-Line Terminal for Windows**
|
|
4
|
+
|
|
5
|
+
NOVA Terminal is a command-line tool developed by **Shivexa** to help developers execute commands, run programs, and manage development workflows from one place.
|
|
6
|
+
|
|
7
|
+
## ✨ Features
|
|
8
|
+
|
|
9
|
+
- 🐍 **Python Support** — Run Python programs and commands.
|
|
10
|
+
- 🟢 **Node.js Support** — Execute Node.js programs when Node.js is installed.
|
|
11
|
+
- 📦 **Package Management** — Work with `pip` and `npm` commands.
|
|
12
|
+
- 🎨 **Colorful Output** — Clear, color-coded terminal messages.
|
|
13
|
+
- ⚙️ **Command Execution** — Execute supported development commands.
|
|
14
|
+
- 💻 **Developer Friendly** — Designed for everyday development workflows.
|
|
15
|
+
|
|
16
|
+
## 📥 Installation
|
|
17
|
+
|
|
18
|
+
Install NOVA Terminal using pip:
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
pip install shivexa-nova-terminal
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## 🚀 Start NOVA
|
|
25
|
+
|
|
26
|
+
After installation, run:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
nova
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## 🛠️ Requirements
|
|
33
|
+
|
|
34
|
+
- Windows operating system is the primary target.
|
|
35
|
+
- Python 3.10 or later.
|
|
36
|
+
- Install Node.js separately if you want to use Node.js features.
|
|
37
|
+
- Some commands require their corresponding tools to be installed and available in PATH.
|
|
38
|
+
|
|
39
|
+
## 💡 Example Usage
|
|
40
|
+
|
|
41
|
+
Run NOVA:
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
nova
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Run a Python script using the supported command syntax in NOVA.
|
|
48
|
+
|
|
49
|
+
Install a Python package using the supported `pip` workflow.
|
|
50
|
+
|
|
51
|
+
Use Node.js commands when Node.js is installed.
|
|
52
|
+
|
|
53
|
+
*Available commands and syntax depend on the NOVA Terminal version.*
|
|
54
|
+
|
|
55
|
+
## 🔒 Security
|
|
56
|
+
|
|
57
|
+
Only execute commands and scripts you trust. Commands may modify files, install software, or change your system.
|
|
58
|
+
|
|
59
|
+
## 🏢 About Shivexa
|
|
60
|
+
|
|
61
|
+
NOVA Terminal is a developer-focused project by **Shivexa**, built to make command-line workflows more accessible and convenient.
|
|
62
|
+
|
|
63
|
+
## 📄 License
|
|
64
|
+
|
|
65
|
+
The license will be specified in a future release. Please check the project's repository for current licensing information.
|
|
66
|
+
|
|
67
|
+
---
|
|
68
|
+
|
|
69
|
+
**Developed with ❤️ by Shivexa**
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
|
|
2
|
+
[build-system]
|
|
3
|
+
requires = ["setuptools>=77", "wheel"]
|
|
4
|
+
build-backend = "setuptools.build_meta"
|
|
5
|
+
|
|
6
|
+
[project]
|
|
7
|
+
name = "shivexa-nova-terminal"
|
|
8
|
+
version = "0.1.0"
|
|
9
|
+
description = "NOVA Terminal for developers"
|
|
10
|
+
readme = "Readme.md"
|
|
11
|
+
requires-python = ">=3.10"
|
|
12
|
+
authors = [
|
|
13
|
+
{ name = "Shivexa" }
|
|
14
|
+
]
|
|
15
|
+
|
|
16
|
+
[project.scripts]
|
|
17
|
+
nova = "nova_terminal.cli:main"
|
|
18
|
+
|
|
19
|
+
[tool.setuptools]
|
|
20
|
+
package-dir = {"" = "src"}
|
|
21
|
+
|
|
22
|
+
[tool.setuptools.packages.find]
|
|
23
|
+
where = ["src"]
|
|
File without changes
|
|
@@ -0,0 +1,474 @@
|
|
|
1
|
+
import os
|
|
2
|
+
import sys
|
|
3
|
+
import time
|
|
4
|
+
import shutil
|
|
5
|
+
import subprocess
|
|
6
|
+
from pathlib import Path
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
if hasattr(sys.stdout, "reconfigure"):
|
|
11
|
+
sys.stdout.reconfigure(encoding="utf-8", errors="replace")
|
|
12
|
+
|
|
13
|
+
CYAN = "\033[38;5;51m"
|
|
14
|
+
PURPLE = "\033[38;5;129m"
|
|
15
|
+
PINK = "\033[38;5;201m"
|
|
16
|
+
GREEN = "\033[38;5;46m"
|
|
17
|
+
GOLD = "\033[38;5;220m"
|
|
18
|
+
WHITE = "\033[1;97m"
|
|
19
|
+
GRAY = "\033[38;5;245m"
|
|
20
|
+
BOLD = "\033[1m"
|
|
21
|
+
RESET = "\033[0m"
|
|
22
|
+
RED = "\033[91m"
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
def run_npm(commands):
|
|
26
|
+
try:
|
|
27
|
+
command = commands[1:]
|
|
28
|
+
check_npm = shutil.which("npm")
|
|
29
|
+
|
|
30
|
+
if check_npm is None:
|
|
31
|
+
print("NOVA: npm command not found please download node js")
|
|
32
|
+
return
|
|
33
|
+
|
|
34
|
+
print(GRAY)
|
|
35
|
+
print(GRAY+"[INIT] Initializing NPM package manager...")
|
|
36
|
+
time.sleep(0.4)
|
|
37
|
+
print("[INIT] Checking Node.js and NPM environment...")
|
|
38
|
+
time.sleep(0.4)
|
|
39
|
+
|
|
40
|
+
print(GREEN + BOLD + "[ OK ] Node.js environment detected")
|
|
41
|
+
time.sleep(0.4)
|
|
42
|
+
|
|
43
|
+
print(GREEN + BOLD + "[ OK ] NPM package manager initialized"+RESET)
|
|
44
|
+
time.sleep(0.4)
|
|
45
|
+
|
|
46
|
+
print(GRAY+f"[INFO] Target package: express {command[1]}")
|
|
47
|
+
print("[INFO] Resolving package dependencies...")
|
|
48
|
+
time.sleep(0.4)
|
|
49
|
+
|
|
50
|
+
print("[FETCH] Connecting to NPM registry...")
|
|
51
|
+
print(GREEN + BOLD + "[ OK ] Registry connection established"+RESET)
|
|
52
|
+
time.sleep(0.4)
|
|
53
|
+
|
|
54
|
+
print(GRAY+"[INSTALL] Downloading package metadata...")
|
|
55
|
+
print("[FETCH] Connecting to NPM registry...")
|
|
56
|
+
|
|
57
|
+
subprocess.Popen([check_npm,*command]).wait()
|
|
58
|
+
# print(GREEN + BOLD + "[SUCCESS] Package installation Completed." + RESET)
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
except Exception as err:
|
|
63
|
+
print(err)
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
def run_pip(commands):
|
|
68
|
+
try:
|
|
69
|
+
command = commands[1:]
|
|
70
|
+
pipCheck = sys.executable
|
|
71
|
+
check_pip = shutil.which(pipCheck)
|
|
72
|
+
|
|
73
|
+
if not pipCheck or not check_pip:
|
|
74
|
+
print("NOVA: pip command not found please download node js")
|
|
75
|
+
return
|
|
76
|
+
|
|
77
|
+
print(GRAY)
|
|
78
|
+
print(GRAY+"[INIT] Initializing pip package manager...")
|
|
79
|
+
time.sleep(0.4)
|
|
80
|
+
print("[INIT] Checking Python and pip environment...")
|
|
81
|
+
time.sleep(0.4)
|
|
82
|
+
|
|
83
|
+
print(GREEN + BOLD + "[ OK ] Python environment detected")
|
|
84
|
+
time.sleep(0.4)
|
|
85
|
+
|
|
86
|
+
print(GREEN + BOLD + "[ OK ] pip package manager initialized"+RESET)
|
|
87
|
+
time.sleep(0.4)
|
|
88
|
+
|
|
89
|
+
print(GRAY+f"[INFO] Target package: express {command[1]}")
|
|
90
|
+
print("[INFO] Resolving package dependencies...")
|
|
91
|
+
time.sleep(0.4)
|
|
92
|
+
|
|
93
|
+
print("[FETCH] Connecting to NPM registry...")
|
|
94
|
+
print(GREEN + BOLD + "[ OK ] Registry connection established"+RESET)
|
|
95
|
+
time.sleep(0.4)
|
|
96
|
+
|
|
97
|
+
print(GRAY+"[INSTALL] Downloading package metadata...")
|
|
98
|
+
print("[FETCH] Connecting to NPM registry...")
|
|
99
|
+
|
|
100
|
+
subprocess.Popen([pipCheck,'-m','pip',*command]).wait()
|
|
101
|
+
# print(GREEN + BOLD + "[SUCCESS] Package installation Completed." + RESET)
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
except Exception as err:
|
|
106
|
+
print(err)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
def wipe():
|
|
111
|
+
# Windows aur Linux dono par screen clear karne ke liye
|
|
112
|
+
os.system('cls' if os.name == 'nt' else 'clear')
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
def say(data):
|
|
118
|
+
concate=""
|
|
119
|
+
if len(data)>1:
|
|
120
|
+
for i in range(1,len(data)):
|
|
121
|
+
concate = concate+" " +data[i]
|
|
122
|
+
print(concate)
|
|
123
|
+
else:
|
|
124
|
+
print("pass correct argument to print")
|
|
125
|
+
|
|
126
|
+
def go(data):
|
|
127
|
+
|
|
128
|
+
try:
|
|
129
|
+
if len(data)>1 and len(data)<3:
|
|
130
|
+
os.chdir(data[1])
|
|
131
|
+
|
|
132
|
+
else:
|
|
133
|
+
print("pass argument\n")
|
|
134
|
+
except Exception as err:
|
|
135
|
+
print(f"file/folder not available: {err}")
|
|
136
|
+
|
|
137
|
+
def helpme():
|
|
138
|
+
print(PURPLE + BOLD + "\n Available commands:")
|
|
139
|
+
print(CYAN + "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n" + RESET)
|
|
140
|
+
|
|
141
|
+
print(WHITE + BOLD + ">> helpme - " + RESET + GRAY + "Show this help message")
|
|
142
|
+
print(WHITE + BOLD +">> wipe - "+ RESET + GRAY + "Clear the terminal screen")
|
|
143
|
+
print(WHITE + BOLD +">> say - "+ RESET + GRAY + "Print a welcome greeting")
|
|
144
|
+
print(WHITE + BOLD +">> recall - "+ RESET + GRAY + "show last 5 history of commands")
|
|
145
|
+
print(WHITE + BOLD +">> close - "+ RESET + GRAY + "Close the shell\n")
|
|
146
|
+
|
|
147
|
+
print(PURPLE + BOLD +" Navigations commands:")
|
|
148
|
+
print(CYAN + "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n" + RESET)
|
|
149
|
+
|
|
150
|
+
print(WHITE + BOLD +">> where - "+ RESET + GRAY + "Close the shell")
|
|
151
|
+
print(WHITE + BOLD +">> show - "+ RESET + GRAY + "Close the shell")
|
|
152
|
+
print(WHITE + BOLD +">> go - "+ RESET + GRAY + "Close the shell")
|
|
153
|
+
print(WHITE + BOLD +">> map - "+ RESET + GRAY + "Close the shell\n")
|
|
154
|
+
|
|
155
|
+
print(PURPLE + BOLD + " File managment commands:")
|
|
156
|
+
print(CYAN + "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n" + RESET)
|
|
157
|
+
|
|
158
|
+
print(WHITE + BOLD +">> newdir - "+ RESET + GRAY + "Close the shell")
|
|
159
|
+
print(WHITE + BOLD +">> deldir - "+ RESET + GRAY + "Close the shell")
|
|
160
|
+
print(WHITE + BOLD +">> newfile - "+ RESET + GRAY + "Close the shell")
|
|
161
|
+
print(WHITE + BOLD +">> read - "+ RESET + GRAY + "Close the shell")
|
|
162
|
+
print(WHITE + BOLD +">> put - "+ RESET + GRAY + "Close the shell")
|
|
163
|
+
print(WHITE + BOLD +">> clone - "+ RESET + GRAY + "Close the shell")
|
|
164
|
+
print(WHITE + BOLD +">> shift - "+ RESET + GRAY + "Close the shell")
|
|
165
|
+
print(WHITE + BOLD +">> erase - "+ RESET + GRAY + "Close the shell\n")
|
|
166
|
+
|
|
167
|
+
print(PURPLE + BOLD + " Search and Text commands:")
|
|
168
|
+
print(CYAN + "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n" + RESET)
|
|
169
|
+
|
|
170
|
+
print(WHITE + BOLD +">> seek - "+ RESET + GRAY + "Close the shell")
|
|
171
|
+
print(WHITE + BOLD +">> first - "+ RESET + GRAY + "Close the shell")
|
|
172
|
+
print(WHITE + BOLD +">> last - "+ RESET + GRAY + "Close the shell")
|
|
173
|
+
print(WHITE + BOLD +">> count - "+ RESET + GRAY + "Close the shell")
|
|
174
|
+
print(WHITE + BOLD +">> locate - "+ RESET + GRAY + "Close the shell\n"+RESET)
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
def show_banner():
|
|
183
|
+
wipe()
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
print()
|
|
188
|
+
print(" \033[96m███╗ ██╗ \033[95m ██████╗ \033[94m ██╗ ██╗ \033[93m █████╗ \033[0m")
|
|
189
|
+
print(" \033[96m████╗ ██║ \033[95m██╔═══██╗\033[94m ██║ ██║ \033[93m██╔══██╗\033[0m")
|
|
190
|
+
print(" \033[96m██╔██╗ ██║ \033[95m██║ ██║\033[94m ██║ ██║ \033[93m███████║\033[0m")
|
|
191
|
+
print(" \033[96m██║╚██╗██║ \033[95m██║ ██║\033[94m ╚██╗ ██╔╝ \033[93m██╔══██║\033[0m")
|
|
192
|
+
print(" \033[96m██║ ╚████║ \033[95m╚██████╔╝\033[94m ╚████╔╝ \033[93m██║ ██║\033[0m")
|
|
193
|
+
print(" \033[96m╚═╝ ╚═══╝ \033[95m ╚═════╝ \033[94m ╚═══╝ \033[93m╚═╝ ╚═╝\033[0m")
|
|
194
|
+
|
|
195
|
+
print(PURPLE + " ╔══════════════════════════════════════════╗" + RESET)
|
|
196
|
+
print(PINK + BOLD + " ║" +"\033[92m" +
|
|
197
|
+
" N O V A T E R M I N A L " + PINK+" ║\n"+ PINK + BOLD + " ║"+ GOLD + "\t A DEVELOPER COMMAND LINE" +
|
|
198
|
+
PINK + "\t ║" + RESET)
|
|
199
|
+
print(PURPLE + " ╚══════════════════════════════════════════╝" + RESET)
|
|
200
|
+
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
# time.sleep(0.5)
|
|
204
|
+
print(GREEN + BOLD + " [✓] " + RESET +
|
|
205
|
+
WHITE + "Terminal initialized" + RESET)
|
|
206
|
+
# time.sleep(0.5)
|
|
207
|
+
|
|
208
|
+
print(GREEN + BOLD + " [✓] " + RESET +
|
|
209
|
+
WHITE + "NOVA Terminal ready" + RESET)
|
|
210
|
+
# print(CYAN + " [i] " + RESET +
|
|
211
|
+
# GRAY + "NOVA version: 1.0.0" + RESET)
|
|
212
|
+
print()
|
|
213
|
+
|
|
214
|
+
print(GOLD + BOLD + " >> " + RESET +
|
|
215
|
+
WHITE + "Type 'helpme' to explore commands." + RESET)
|
|
216
|
+
print(CYAN + " ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━" + RESET)
|
|
217
|
+
print()
|
|
218
|
+
|
|
219
|
+
# time.sleep(0.5)
|
|
220
|
+
|
|
221
|
+
# print(PURPLE + " ╔══════════════════════════════════════════╗" + RESET)
|
|
222
|
+
# print(PINK + BOLD + " ║" + WHITE +
|
|
223
|
+
# " SHIVEXA SHELL [Version 1.0.0] " +
|
|
224
|
+
# PINK + "║" + RESET)
|
|
225
|
+
# print(PURPLE + " ╚══════════════════════════════════════════╝" + RESET)
|
|
226
|
+
|
|
227
|
+
# print(CYAN + " Powered by " + PINK + BOLD + "SHIVEXA" + RESET +
|
|
228
|
+
# CYAN + " | Type " + GOLD + "'helpme'" +
|
|
229
|
+
# CYAN + " for commands." + RESET)
|
|
230
|
+
# print(CYAN + " Type " + GOLD + "'close'" +
|
|
231
|
+
# CYAN + " to close the terminal." + RESET)
|
|
232
|
+
|
|
233
|
+
# print(PURPLE + " ════════════════════════════════════════════" + RESET)
|
|
234
|
+
# print()
|
|
235
|
+
|
|
236
|
+
def node(command):
|
|
237
|
+
try:
|
|
238
|
+
|
|
239
|
+
check = shutil.which("node")
|
|
240
|
+
if check is None:
|
|
241
|
+
print("install node")
|
|
242
|
+
return
|
|
243
|
+
subprocess.Popen([check,*command[1:]]).wait()
|
|
244
|
+
|
|
245
|
+
except Exception as err:
|
|
246
|
+
print(RED + BOLD + err+ RESET)
|
|
247
|
+
|
|
248
|
+
def python(command):
|
|
249
|
+
try:
|
|
250
|
+
python = shutil.which("python")
|
|
251
|
+
# check = shutil.which(sys.executable)
|
|
252
|
+
if not python:
|
|
253
|
+
print("install python")
|
|
254
|
+
return
|
|
255
|
+
result = subprocess.Popen([python,*command[1:]]).wait()
|
|
256
|
+
|
|
257
|
+
|
|
258
|
+
except Exception as err:
|
|
259
|
+
print(RED + BOLD + err+ RESET)
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
|
|
263
|
+
def run_jscode(filename):
|
|
264
|
+
source = Path(filename).expanduser().resolve()
|
|
265
|
+
node = shutil.which("node")
|
|
266
|
+
|
|
267
|
+
if node is None:
|
|
268
|
+
print("install node")
|
|
269
|
+
return
|
|
270
|
+
|
|
271
|
+
if not source.is_file():
|
|
272
|
+
print("javascript file not found")
|
|
273
|
+
return
|
|
274
|
+
|
|
275
|
+
if source.suffix !=".js":
|
|
276
|
+
print(".js must")
|
|
277
|
+
return
|
|
278
|
+
try:
|
|
279
|
+
|
|
280
|
+
check = subprocess.run(
|
|
281
|
+
[node, "--check",str(source)],
|
|
282
|
+
capture_output=True,
|
|
283
|
+
text= True,
|
|
284
|
+
check=False
|
|
285
|
+
)
|
|
286
|
+
|
|
287
|
+
|
|
288
|
+
if check.returncode != 0:
|
|
289
|
+
print(check.stderr or check.stdout,end="")
|
|
290
|
+
return
|
|
291
|
+
|
|
292
|
+
except Exception as err:
|
|
293
|
+
print(err)
|
|
294
|
+
|
|
295
|
+
|
|
296
|
+
try:
|
|
297
|
+
|
|
298
|
+
run = subprocess.run([node,str(source)],cwd=str(source.parent),check=False)
|
|
299
|
+
if run.returncode == 0:
|
|
300
|
+
print("program run..")
|
|
301
|
+
else:
|
|
302
|
+
print("exit with code 0")
|
|
303
|
+
except Exception as err:
|
|
304
|
+
print(err)
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
|
|
311
|
+
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
def run_pycode(filename):
|
|
315
|
+
source = Path(filename).expanduser().resolve()
|
|
316
|
+
python_path = shutil.which("python")
|
|
317
|
+
if not sys.executable or python_path is None:
|
|
318
|
+
print("install python")
|
|
319
|
+
return
|
|
320
|
+
|
|
321
|
+
if not source.is_file():
|
|
322
|
+
print("python file not found")
|
|
323
|
+
return
|
|
324
|
+
|
|
325
|
+
if source.suffix != ".py":
|
|
326
|
+
print(".py must")
|
|
327
|
+
return
|
|
328
|
+
try:
|
|
329
|
+
check = subprocess.run(
|
|
330
|
+
[python_path,"-m", "py_compile",str(source)],
|
|
331
|
+
capture_output=True,
|
|
332
|
+
text= True,
|
|
333
|
+
encoding="utf-8",
|
|
334
|
+
errors="replace",
|
|
335
|
+
shell=False
|
|
336
|
+
)
|
|
337
|
+
|
|
338
|
+
|
|
339
|
+
|
|
340
|
+
if check.returncode != 0:
|
|
341
|
+
print(check.stderr or check.stdout,end="")
|
|
342
|
+
return
|
|
343
|
+
|
|
344
|
+
except Exception as err:
|
|
345
|
+
print(err)
|
|
346
|
+
|
|
347
|
+
|
|
348
|
+
try:
|
|
349
|
+
run = subprocess.run([python_path,str(source)],cwd=os.getcwd(),encoding="utf-8",
|
|
350
|
+
errors="replace",shell=False)
|
|
351
|
+
if run.returncode == 0:
|
|
352
|
+
print("program run..")
|
|
353
|
+
else:
|
|
354
|
+
print("exit with code 0")
|
|
355
|
+
except Exception as err:
|
|
356
|
+
print(err)
|
|
357
|
+
|
|
358
|
+
|
|
359
|
+
def runpy(command):
|
|
360
|
+
if len(command) !=3:
|
|
361
|
+
print("invalid command")
|
|
362
|
+
return
|
|
363
|
+
|
|
364
|
+
language = command[1].lower()
|
|
365
|
+
filename = command[2].lower()
|
|
366
|
+
if language != "python":
|
|
367
|
+
print("only support python or node")
|
|
368
|
+
return
|
|
369
|
+
|
|
370
|
+
run_pycode(filename)
|
|
371
|
+
|
|
372
|
+
|
|
373
|
+
def runjs(command):
|
|
374
|
+
if len(command) !=3:
|
|
375
|
+
print("invalid command")
|
|
376
|
+
return
|
|
377
|
+
|
|
378
|
+
language = command[1].lower()
|
|
379
|
+
filename = command[2].lower()
|
|
380
|
+
if language != "node":
|
|
381
|
+
print("only support python or node")
|
|
382
|
+
return
|
|
383
|
+
|
|
384
|
+
run_jscode(filename)
|
|
385
|
+
|
|
386
|
+
def main():
|
|
387
|
+
show_banner()
|
|
388
|
+
|
|
389
|
+
while True:
|
|
390
|
+
try:
|
|
391
|
+
# User se command input lena
|
|
392
|
+
|
|
393
|
+
|
|
394
|
+
command = input(GOLD + BOLD + "NOVA "+GRAY+ "[" + os.getcwd() + "]" + GOLD +" > "+ RESET).strip()
|
|
395
|
+
user_input = command.split()
|
|
396
|
+
|
|
397
|
+
# Agar user khali enter press kare
|
|
398
|
+
if not user_input:
|
|
399
|
+
continue
|
|
400
|
+
|
|
401
|
+
# Commands Logic
|
|
402
|
+
if user_input[0] == "close":
|
|
403
|
+
print("Closing Shivexa Nova Terminal. Goodbye!")
|
|
404
|
+
break
|
|
405
|
+
|
|
406
|
+
elif user_input[0] == "wipe":
|
|
407
|
+
show_banner()
|
|
408
|
+
|
|
409
|
+
elif command.startswith('npm'):
|
|
410
|
+
run_npm(user_input)
|
|
411
|
+
|
|
412
|
+
elif command.startswith('pip'):
|
|
413
|
+
run_pip(user_input)
|
|
414
|
+
|
|
415
|
+
elif command.startswith('run'):
|
|
416
|
+
runpy(user_input)
|
|
417
|
+
|
|
418
|
+
elif command.startswith('start'):
|
|
419
|
+
runjs(user_input)
|
|
420
|
+
|
|
421
|
+
elif user_input[0] == "helpme":
|
|
422
|
+
helpme()
|
|
423
|
+
|
|
424
|
+
elif user_input[0] == "say":
|
|
425
|
+
say(user_input)
|
|
426
|
+
|
|
427
|
+
elif user_input[0] == "where":
|
|
428
|
+
print(WHITE + BOLD + "✓ CURRENT PATH" + RESET)
|
|
429
|
+
print(GRAY +">> " + os.getcwd() + RESET)
|
|
430
|
+
|
|
431
|
+
elif user_input[0] == "show":
|
|
432
|
+
print(PURPLE + BOLD+ "\n Type \t\t\t Name")
|
|
433
|
+
print(BOLD+ "______________________________________________\n"+RESET)
|
|
434
|
+
for i in os.listdir():
|
|
435
|
+
if os.path.isdir(i):
|
|
436
|
+
print(BOLD + "📁 [DIR]"+RESET + GRAY + f" \t\t\t {i}"+RESET)
|
|
437
|
+
|
|
438
|
+
else:
|
|
439
|
+
print(BOLD +"📄 [FILE] "+RESET + GRAY + f" \t\t\t {i}"+ RESET)
|
|
440
|
+
print()
|
|
441
|
+
|
|
442
|
+
elif user_input[0] == "go":
|
|
443
|
+
go(user_input)
|
|
444
|
+
|
|
445
|
+
elif user_input[0] == "node":
|
|
446
|
+
node(user_input)
|
|
447
|
+
|
|
448
|
+
elif user_input[0] == "python":
|
|
449
|
+
python(user_input)
|
|
450
|
+
|
|
451
|
+
elif user_input[0] == "newdir":
|
|
452
|
+
os.mkdir(user_input[1])
|
|
453
|
+
print(f"directory Created Successful")
|
|
454
|
+
|
|
455
|
+
elif user_input[0] == "deldir":
|
|
456
|
+
os.rmdir(user_input[1])
|
|
457
|
+
print(f"directory deleted Successful")
|
|
458
|
+
|
|
459
|
+
else:
|
|
460
|
+
# Agar command standard list me nahi hai to Linux jaisa error
|
|
461
|
+
print(f"nova: command not found {user_input[0]}" + RESET)
|
|
462
|
+
|
|
463
|
+
except (KeyboardInterrupt, EOFError):
|
|
464
|
+
print()
|
|
465
|
+
pass
|
|
466
|
+
|
|
467
|
+
|
|
468
|
+
if __name__ == "__main__":
|
|
469
|
+
main()
|
|
470
|
+
|
|
471
|
+
|
|
472
|
+
|
|
473
|
+
# ✔ Success: Folder 'components' created successfully.
|
|
474
|
+
# ✖ Error: Folder 'src' already exists.
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: shivexa-nova-terminal
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: NOVA Terminal for developers
|
|
5
|
+
Author: Shivexa
|
|
6
|
+
Requires-Python: >=3.10
|
|
7
|
+
Description-Content-Type: text/markdown
|
|
8
|
+
|
|
9
|
+
# ⚡ Shivexa NOVA Terminal
|
|
10
|
+
|
|
11
|
+
**A Developer-Focused Command-Line Terminal for Windows**
|
|
12
|
+
|
|
13
|
+
NOVA Terminal is a command-line tool developed by **Shivexa** to help developers execute commands, run programs, and manage development workflows from one place.
|
|
14
|
+
|
|
15
|
+
## ✨ Features
|
|
16
|
+
|
|
17
|
+
- 🐍 **Python Support** — Run Python programs and commands.
|
|
18
|
+
- 🟢 **Node.js Support** — Execute Node.js programs when Node.js is installed.
|
|
19
|
+
- 📦 **Package Management** — Work with `pip` and `npm` commands.
|
|
20
|
+
- 🎨 **Colorful Output** — Clear, color-coded terminal messages.
|
|
21
|
+
- ⚙️ **Command Execution** — Execute supported development commands.
|
|
22
|
+
- 💻 **Developer Friendly** — Designed for everyday development workflows.
|
|
23
|
+
|
|
24
|
+
## 📥 Installation
|
|
25
|
+
|
|
26
|
+
Install NOVA Terminal using pip:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
pip install shivexa-nova-terminal
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## 🚀 Start NOVA
|
|
33
|
+
|
|
34
|
+
After installation, run:
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
nova
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## 🛠️ Requirements
|
|
41
|
+
|
|
42
|
+
- Windows operating system is the primary target.
|
|
43
|
+
- Python 3.10 or later.
|
|
44
|
+
- Install Node.js separately if you want to use Node.js features.
|
|
45
|
+
- Some commands require their corresponding tools to be installed and available in PATH.
|
|
46
|
+
|
|
47
|
+
## 💡 Example Usage
|
|
48
|
+
|
|
49
|
+
Run NOVA:
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
nova
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Run a Python script using the supported command syntax in NOVA.
|
|
56
|
+
|
|
57
|
+
Install a Python package using the supported `pip` workflow.
|
|
58
|
+
|
|
59
|
+
Use Node.js commands when Node.js is installed.
|
|
60
|
+
|
|
61
|
+
*Available commands and syntax depend on the NOVA Terminal version.*
|
|
62
|
+
|
|
63
|
+
## 🔒 Security
|
|
64
|
+
|
|
65
|
+
Only execute commands and scripts you trust. Commands may modify files, install software, or change your system.
|
|
66
|
+
|
|
67
|
+
## 🏢 About Shivexa
|
|
68
|
+
|
|
69
|
+
NOVA Terminal is a developer-focused project by **Shivexa**, built to make command-line workflows more accessible and convenient.
|
|
70
|
+
|
|
71
|
+
## 📄 License
|
|
72
|
+
|
|
73
|
+
The license will be specified in a future release. Please check the project's repository for current licensing information.
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
**Developed with ❤️ by Shivexa**
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
Readme.md
|
|
2
|
+
pyproject.toml
|
|
3
|
+
src/nova_terminal/__init__.py
|
|
4
|
+
src/nova_terminal/cli.py
|
|
5
|
+
src/nova_terminal/nova.py
|
|
6
|
+
src/shivexa_nova_terminal.egg-info/PKG-INFO
|
|
7
|
+
src/shivexa_nova_terminal.egg-info/SOURCES.txt
|
|
8
|
+
src/shivexa_nova_terminal.egg-info/dependency_links.txt
|
|
9
|
+
src/shivexa_nova_terminal.egg-info/entry_points.txt
|
|
10
|
+
src/shivexa_nova_terminal.egg-info/top_level.txt
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
nova_terminal
|