Add 3 files
Browse files- README.md +6 -4
- index.html +1534 -19
- prompts.txt +1 -0
README.md
CHANGED
@@ -1,10 +1,12 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
colorTo: purple
|
6 |
sdk: static
|
7 |
pinned: false
|
|
|
|
|
8 |
---
|
9 |
|
10 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
1 |
---
|
2 |
+
title: searchable-library-of-terminal-commands
|
3 |
+
emoji: 🐳
|
4 |
+
colorFrom: gray
|
5 |
colorTo: purple
|
6 |
sdk: static
|
7 |
pinned: false
|
8 |
+
tags:
|
9 |
+
- deepsite
|
10 |
---
|
11 |
|
12 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
index.html
CHANGED
@@ -1,19 +1,1534 @@
|
|
1 |
-
<!
|
2 |
-
<html>
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<!DOCTYPE html>
|
2 |
+
<html lang="en">
|
3 |
+
<head>
|
4 |
+
<meta charset="UTF-8">
|
5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6 |
+
<title>Terminal Commands Library</title>
|
7 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
8 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
9 |
+
<style>
|
10 |
+
.command-card {
|
11 |
+
transition: all 0.2s ease;
|
12 |
+
}
|
13 |
+
.command-card:hover {
|
14 |
+
transform: translateY(-2px);
|
15 |
+
box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
16 |
+
}
|
17 |
+
.copy-btn {
|
18 |
+
opacity: 0;
|
19 |
+
transition: opacity 0.2s ease;
|
20 |
+
}
|
21 |
+
.command-card:hover .copy-btn {
|
22 |
+
opacity: 1;
|
23 |
+
}
|
24 |
+
.tag {
|
25 |
+
transition: all 0.2s ease;
|
26 |
+
}
|
27 |
+
.tag:hover {
|
28 |
+
transform: scale(1.05);
|
29 |
+
}
|
30 |
+
.search-highlight {
|
31 |
+
background-color: #FEF08A;
|
32 |
+
padding: 0 2px;
|
33 |
+
border-radius: 2px;
|
34 |
+
}
|
35 |
+
.category-badge {
|
36 |
+
position: absolute;
|
37 |
+
top: -10px;
|
38 |
+
right: 10px;
|
39 |
+
font-size: 0.7rem;
|
40 |
+
padding: 2px 8px;
|
41 |
+
border-radius: 9999px;
|
42 |
+
}
|
43 |
+
</style>
|
44 |
+
</head>
|
45 |
+
<body class="bg-gray-50 min-h-screen">
|
46 |
+
<div class="container mx-auto px-4 py-8">
|
47 |
+
<!-- Header -->
|
48 |
+
<header class="mb-10 text-center">
|
49 |
+
<h1 class="text-4xl font-bold text-gray-800 mb-2">
|
50 |
+
<i class="fas fa-terminal mr-3 text-indigo-600"></i>
|
51 |
+
Terminal Commands Library
|
52 |
+
</h1>
|
53 |
+
<p class="text-gray-600 max-w-2xl mx-auto">
|
54 |
+
Search and discover useful terminal commands for various operating systems and tools.
|
55 |
+
Click any command to copy it to your clipboard.
|
56 |
+
</p>
|
57 |
+
</header>
|
58 |
+
|
59 |
+
<!-- Search and Filter -->
|
60 |
+
<div class="mb-8 bg-white rounded-xl shadow-md p-6">
|
61 |
+
<div class="flex flex-col md:flex-row gap-4">
|
62 |
+
<div class="flex-1 relative">
|
63 |
+
<div class="absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none">
|
64 |
+
<i class="fas fa-search text-gray-400"></i>
|
65 |
+
</div>
|
66 |
+
<input
|
67 |
+
type="text"
|
68 |
+
id="searchInput"
|
69 |
+
placeholder="Search commands (e.g. 'git', 'find files')..."
|
70 |
+
class="w-full pl-10 pr-4 py-3 border border-gray-300 rounded-lg focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500"
|
71 |
+
>
|
72 |
+
</div>
|
73 |
+
<select id="osFilter" class="border border-gray-300 rounded-lg px-4 py-3 focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500">
|
74 |
+
<option value="all">All OS</option>
|
75 |
+
<option value="linux">Linux</option>
|
76 |
+
<option value="macos">macOS</option>
|
77 |
+
<option value="windows">Windows</option>
|
78 |
+
</select>
|
79 |
+
<select id="categoryFilter" class="border border-gray-300 rounded-lg px-4 py-3 focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500">
|
80 |
+
<option value="all">All Categories</option>
|
81 |
+
<option value="file">File Operations</option>
|
82 |
+
<option value="network">Network</option>
|
83 |
+
<option value="system">System Info</option>
|
84 |
+
<option value="process">Processes</option>
|
85 |
+
<option value="git">Git</option>
|
86 |
+
<option value="docker">Docker</option>
|
87 |
+
<option value="permissions">Permissions</option>
|
88 |
+
<option value="compression">Compression</option>
|
89 |
+
<option value="text">Text Processing</option>
|
90 |
+
<option value="package">Package Managers</option>
|
91 |
+
<option value="ssh">SSH</option>
|
92 |
+
</select>
|
93 |
+
</div>
|
94 |
+
<div class="mt-4 flex flex-wrap gap-2" id="popularTags">
|
95 |
+
<span class="text-sm text-gray-500 mr-2">Popular:</span>
|
96 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="git">Git</button>
|
97 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="docker">Docker</button>
|
98 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="permissions">Permissions</button>
|
99 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="find">Find Files</button>
|
100 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="process">Processes</button>
|
101 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="network">Network</button>
|
102 |
+
<button class="tag px-3 py-1 bg-indigo-100 text-indigo-800 rounded-full text-sm hover:bg-indigo-200" data-tag="ssh">SSH</button>
|
103 |
+
</div>
|
104 |
+
</div>
|
105 |
+
|
106 |
+
<!-- Stats -->
|
107 |
+
<div class="mb-6 flex flex-wrap gap-4 justify-center">
|
108 |
+
<div class="bg-white rounded-lg shadow p-4 text-center min-w-[120px]">
|
109 |
+
<div class="text-2xl font-bold text-indigo-600" id="totalCommands">0</div>
|
110 |
+
<div class="text-gray-500 text-sm">Total Commands</div>
|
111 |
+
</div>
|
112 |
+
<div class="bg-white rounded-lg shadow p-4 text-center min-w-[120px]">
|
113 |
+
<div class="text-2xl font-bold text-indigo-600" id="linuxCount">0</div>
|
114 |
+
<div class="text-gray-500 text-sm">Linux</div>
|
115 |
+
</div>
|
116 |
+
<div class="bg-white rounded-lg shadow p-4 text-center min-w-[120px]">
|
117 |
+
<div class="text-2xl font-bold text-indigo-600" id="macosCount">0</div>
|
118 |
+
<div class="text-gray-500 text-sm">macOS</div>
|
119 |
+
</div>
|
120 |
+
<div class="bg-white rounded-lg shadow p-4 text-center min-w-[120px]">
|
121 |
+
<div class="text-2xl font-bold text-indigo-600" id="windowsCount">0</div>
|
122 |
+
<div class="text-gray-500 text-sm">Windows</div>
|
123 |
+
</div>
|
124 |
+
</div>
|
125 |
+
|
126 |
+
<!-- Commands Grid -->
|
127 |
+
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6" id="commandsContainer">
|
128 |
+
<!-- Commands will be inserted here by JavaScript -->
|
129 |
+
</div>
|
130 |
+
|
131 |
+
<!-- Empty State -->
|
132 |
+
<div id="emptyState" class="text-center py-16 hidden">
|
133 |
+
<i class="fas fa-search fa-3x text-gray-300 mb-4"></i>
|
134 |
+
<h3 class="text-xl font-medium text-gray-700">No commands found</h3>
|
135 |
+
<p class="text-gray-500 mt-2">Try adjusting your search or filters</p>
|
136 |
+
</div>
|
137 |
+
</div>
|
138 |
+
|
139 |
+
<!-- Toast Notification -->
|
140 |
+
<div id="toast" class="fixed bottom-4 right-4 bg-green-500 text-white px-6 py-3 rounded-lg shadow-lg transform translate-y-10 opacity-0 transition-all duration-300 flex items-center">
|
141 |
+
<i class="fas fa-check-circle mr-2"></i>
|
142 |
+
<span>Command copied to clipboard!</span>
|
143 |
+
</div>
|
144 |
+
|
145 |
+
<script>
|
146 |
+
// Comprehensive command data
|
147 |
+
const commands = [
|
148 |
+
// File Operations
|
149 |
+
{
|
150 |
+
id: 1,
|
151 |
+
command: "ls -la",
|
152 |
+
description: "List all files and directories (including hidden ones) with details",
|
153 |
+
os: ["linux", "macos"],
|
154 |
+
category: "file",
|
155 |
+
tags: ["list", "directory", "files"],
|
156 |
+
usage: "ls -la /path/to/directory"
|
157 |
+
},
|
158 |
+
{
|
159 |
+
id: 2,
|
160 |
+
command: "cd ~",
|
161 |
+
description: "Change to home directory",
|
162 |
+
os: ["linux", "macos", "windows"],
|
163 |
+
category: "file",
|
164 |
+
tags: ["navigation", "directory"],
|
165 |
+
usage: "cd ~"
|
166 |
+
},
|
167 |
+
{
|
168 |
+
id: 3,
|
169 |
+
command: "pwd",
|
170 |
+
description: "Print working directory (show current directory path)",
|
171 |
+
os: ["linux", "macos", "windows"],
|
172 |
+
category: "file",
|
173 |
+
tags: ["path", "directory"],
|
174 |
+
usage: "pwd"
|
175 |
+
},
|
176 |
+
{
|
177 |
+
id: 4,
|
178 |
+
command: "mkdir -p path/to/dir",
|
179 |
+
description: "Create directory and all parent directories if they don't exist",
|
180 |
+
os: ["linux", "macos", "windows"],
|
181 |
+
category: "file",
|
182 |
+
tags: ["create", "directory"],
|
183 |
+
usage: "mkdir -p project/src/components"
|
184 |
+
},
|
185 |
+
{
|
186 |
+
id: 5,
|
187 |
+
command: "cp -r source destination",
|
188 |
+
description: "Copy files and directories recursively",
|
189 |
+
os: ["linux", "macos"],
|
190 |
+
category: "file",
|
191 |
+
tags: ["copy", "files"],
|
192 |
+
usage: "cp -r old_folder new_folder"
|
193 |
+
},
|
194 |
+
{
|
195 |
+
id: 6,
|
196 |
+
command: "mv oldname newname",
|
197 |
+
description: "Move or rename files and directories",
|
198 |
+
os: ["linux", "macos"],
|
199 |
+
category: "file",
|
200 |
+
tags: ["move", "rename"],
|
201 |
+
usage: "mv oldname.txt newname.txt"
|
202 |
+
},
|
203 |
+
{
|
204 |
+
id: 7,
|
205 |
+
command: "rm -rf directory",
|
206 |
+
description: "Remove directory and its contents recursively (forcefully)",
|
207 |
+
os: ["linux", "macos"],
|
208 |
+
category: "file",
|
209 |
+
tags: ["delete", "remove"],
|
210 |
+
usage: "rm -rf old_project"
|
211 |
+
},
|
212 |
+
{
|
213 |
+
id: 8,
|
214 |
+
command: "find /path -name \"*.txt\"",
|
215 |
+
description: "Find all .txt files in specified directory and subdirectories",
|
216 |
+
os: ["linux", "macos"],
|
217 |
+
category: "file",
|
218 |
+
tags: ["find", "search", "file"],
|
219 |
+
usage: "find ~/Documents -name \"*.txt\""
|
220 |
+
},
|
221 |
+
{
|
222 |
+
id: 9,
|
223 |
+
command: "locate filename",
|
224 |
+
description: "Find files by name using prebuilt database (faster than find)",
|
225 |
+
os: ["linux", "macos"],
|
226 |
+
category: "file",
|
227 |
+
tags: ["find", "search", "file"],
|
228 |
+
usage: "locate myfile.txt"
|
229 |
+
},
|
230 |
+
{
|
231 |
+
id: 10,
|
232 |
+
command: "touch filename",
|
233 |
+
description: "Create empty file or update file's access/modification time",
|
234 |
+
os: ["linux", "macos"],
|
235 |
+
category: "file",
|
236 |
+
tags: ["create", "file"],
|
237 |
+
usage: "touch newfile.txt"
|
238 |
+
},
|
239 |
+
{
|
240 |
+
id: 11,
|
241 |
+
command: "cat file1 file2 > combined",
|
242 |
+
description: "Concatenate files and print/output to another file",
|
243 |
+
os: ["linux", "macos"],
|
244 |
+
category: "file",
|
245 |
+
tags: ["concatenate", "view"],
|
246 |
+
usage: "cat part1.txt part2.txt > complete.txt"
|
247 |
+
},
|
248 |
+
{
|
249 |
+
id: 12,
|
250 |
+
command: "less filename",
|
251 |
+
description: "View file contents with pagination (press q to quit)",
|
252 |
+
os: ["linux", "macos"],
|
253 |
+
category: "file",
|
254 |
+
tags: ["view", "pager"],
|
255 |
+
usage: "less large_log_file.log"
|
256 |
+
},
|
257 |
+
{
|
258 |
+
id: 13,
|
259 |
+
command: "head -n 10 filename",
|
260 |
+
description: "Show first 10 lines of a file",
|
261 |
+
os: ["linux", "macos"],
|
262 |
+
category: "file",
|
263 |
+
tags: ["view", "head"],
|
264 |
+
usage: "head -n 10 access.log"
|
265 |
+
},
|
266 |
+
{
|
267 |
+
id: 14,
|
268 |
+
command: "tail -f filename",
|
269 |
+
description: "Show last lines of a file and follow for new additions",
|
270 |
+
os: ["linux", "macos"],
|
271 |
+
category: "file",
|
272 |
+
tags: ["view", "tail", "logs"],
|
273 |
+
usage: "tail -f /var/log/syslog"
|
274 |
+
},
|
275 |
+
{
|
276 |
+
id: 15,
|
277 |
+
command: "grep -r \"search term\" /path",
|
278 |
+
description: "Recursively search for text in files within a directory",
|
279 |
+
os: ["linux", "macos"],
|
280 |
+
category: "file",
|
281 |
+
tags: ["search", "text", "file"],
|
282 |
+
usage: "grep -r \"error\" /var/log/"
|
283 |
+
},
|
284 |
+
{
|
285 |
+
id: 16,
|
286 |
+
command: "diff file1 file2",
|
287 |
+
description: "Compare two files line by line",
|
288 |
+
os: ["linux", "macos"],
|
289 |
+
category: "file",
|
290 |
+
tags: ["compare", "difference"],
|
291 |
+
usage: "diff original.txt modified.txt"
|
292 |
+
},
|
293 |
+
{
|
294 |
+
id: 17,
|
295 |
+
command: "wc -l filename",
|
296 |
+
description: "Count lines in a file",
|
297 |
+
os: ["linux", "macos"],
|
298 |
+
category: "file",
|
299 |
+
tags: ["count", "lines"],
|
300 |
+
usage: "wc -l users.csv"
|
301 |
+
},
|
302 |
+
{
|
303 |
+
id: 18,
|
304 |
+
command: "du -sh *",
|
305 |
+
description: "Show disk usage of files and directories in human-readable format",
|
306 |
+
os: ["linux", "macos"],
|
307 |
+
category: "file",
|
308 |
+
tags: ["disk", "usage"],
|
309 |
+
usage: "du -sh /home/*"
|
310 |
+
},
|
311 |
+
{
|
312 |
+
id: 19,
|
313 |
+
command: "df -h",
|
314 |
+
description: "Show disk filesystem information in human-readable format",
|
315 |
+
os: ["linux", "macos"],
|
316 |
+
category: "file",
|
317 |
+
tags: ["disk", "space"],
|
318 |
+
usage: "df -h"
|
319 |
+
},
|
320 |
+
{
|
321 |
+
id: 20,
|
322 |
+
command: "ln -s target linkname",
|
323 |
+
description: "Create symbolic link (shortcut) to target file/directory",
|
324 |
+
os: ["linux", "macos"],
|
325 |
+
category: "file",
|
326 |
+
tags: ["link", "symlink"],
|
327 |
+
usage: "ln -s /var/www/html myweb"
|
328 |
+
},
|
329 |
+
|
330 |
+
// Permissions
|
331 |
+
{
|
332 |
+
id: 21,
|
333 |
+
command: "chmod 755 <file>",
|
334 |
+
description: "Change file permissions to rwxr-xr-x (owner can read/write/execute, others can read/execute)",
|
335 |
+
os: ["linux", "macos"],
|
336 |
+
category: "permissions",
|
337 |
+
tags: ["permissions", "file"],
|
338 |
+
usage: "chmod 755 script.sh"
|
339 |
+
},
|
340 |
+
{
|
341 |
+
id: 22,
|
342 |
+
command: "chmod +x filename",
|
343 |
+
description: "Make file executable",
|
344 |
+
os: ["linux", "macos"],
|
345 |
+
category: "permissions",
|
346 |
+
tags: ["permissions", "executable"],
|
347 |
+
usage: "chmod +x install.sh"
|
348 |
+
},
|
349 |
+
{
|
350 |
+
id: 23,
|
351 |
+
command: "chown user:group file",
|
352 |
+
description: "Change file owner and group",
|
353 |
+
os: ["linux", "macos"],
|
354 |
+
category: "permissions",
|
355 |
+
tags: ["owner", "permissions"],
|
356 |
+
usage: "chown www-data:www-data index.php"
|
357 |
+
},
|
358 |
+
{
|
359 |
+
id: 24,
|
360 |
+
command: "sudo !!",
|
361 |
+
description: "Run previous command with sudo privileges",
|
362 |
+
os: ["linux", "macos"],
|
363 |
+
category: "permissions",
|
364 |
+
tags: ["sudo", "privileges"],
|
365 |
+
usage: "sudo !!"
|
366 |
+
},
|
367 |
+
{
|
368 |
+
id: 25,
|
369 |
+
command: "umask 022",
|
370 |
+
description: "Set default permissions for newly created files (777-022=755)",
|
371 |
+
os: ["linux", "macos"],
|
372 |
+
category: "permissions",
|
373 |
+
tags: ["permissions", "default"],
|
374 |
+
usage: "umask 022"
|
375 |
+
},
|
376 |
+
|
377 |
+
// Network
|
378 |
+
{
|
379 |
+
id: 26,
|
380 |
+
command: "ping google.com",
|
381 |
+
description: "Check network connectivity to a host",
|
382 |
+
os: ["linux", "macos", "windows"],
|
383 |
+
category: "network",
|
384 |
+
tags: ["network", "diagnostics"],
|
385 |
+
usage: "ping google.com"
|
386 |
+
},
|
387 |
+
{
|
388 |
+
id: 27,
|
389 |
+
command: "ifconfig",
|
390 |
+
description: "Display network interface configuration (Linux/macOS)",
|
391 |
+
os: ["linux", "macos"],
|
392 |
+
category: "network",
|
393 |
+
tags: ["network", "ip"],
|
394 |
+
usage: "ifconfig"
|
395 |
+
},
|
396 |
+
{
|
397 |
+
id: 28,
|
398 |
+
command: "ipconfig /all",
|
399 |
+
description: "Display all network interface configuration (Windows)",
|
400 |
+
os: ["windows"],
|
401 |
+
category: "network",
|
402 |
+
tags: ["network", "ip"],
|
403 |
+
usage: "ipconfig /all"
|
404 |
+
},
|
405 |
+
{
|
406 |
+
id: 29,
|
407 |
+
command: "netstat -tulnp",
|
408 |
+
description: "List all listening ports and associated programs",
|
409 |
+
os: ["linux", "macos"],
|
410 |
+
category: "network",
|
411 |
+
tags: ["ports", "network"],
|
412 |
+
usage: "netstat -tulnp"
|
413 |
+
},
|
414 |
+
{
|
415 |
+
id: 30,
|
416 |
+
command: "traceroute google.com",
|
417 |
+
description: "Trace route packets take to a network host",
|
418 |
+
os: ["linux", "macos"],
|
419 |
+
category: "network",
|
420 |
+
tags: ["network", "diagnostics"],
|
421 |
+
usage: "traceroute google.com"
|
422 |
+
},
|
423 |
+
{
|
424 |
+
id: 31,
|
425 |
+
command: "dig example.com",
|
426 |
+
description: "DNS lookup utility",
|
427 |
+
os: ["linux", "macos"],
|
428 |
+
category: "network",
|
429 |
+
tags: ["dns", "network"],
|
430 |
+
usage: "dig example.com"
|
431 |
+
},
|
432 |
+
{
|
433 |
+
id: 32,
|
434 |
+
command: "nslookup example.com",
|
435 |
+
description: "Query Internet name servers interactively",
|
436 |
+
os: ["linux", "macos", "windows"],
|
437 |
+
category: "network",
|
438 |
+
tags: ["dns", "network"],
|
439 |
+
usage: "nslookup example.com"
|
440 |
+
},
|
441 |
+
{
|
442 |
+
id: 33,
|
443 |
+
command: "wget http://example.com/file",
|
444 |
+
description: "Download file from the web",
|
445 |
+
os: ["linux", "macos"],
|
446 |
+
category: "network",
|
447 |
+
tags: ["download", "web"],
|
448 |
+
usage: "wget https://example.com/file.zip"
|
449 |
+
},
|
450 |
+
{
|
451 |
+
id: 34,
|
452 |
+
command: "curl -O http://example.com/file",
|
453 |
+
description: "Download file using curl",
|
454 |
+
os: ["linux", "macos"],
|
455 |
+
category: "network",
|
456 |
+
tags: ["download", "web"],
|
457 |
+
usage: "curl -O https://example.com/file.zip"
|
458 |
+
},
|
459 |
+
{
|
460 |
+
id: 35,
|
461 |
+
command: "ssh user@host",
|
462 |
+
description: "Connect to a remote server using SSH",
|
463 |
+
os: ["linux", "macos", "windows"],
|
464 |
+
category: "ssh",
|
465 |
+
tags: ["ssh", "remote"],
|
466 |
+
usage: "ssh [email protected]"
|
467 |
+
},
|
468 |
+
{
|
469 |
+
id: 36,
|
470 |
+
command: "scp file user@host:path",
|
471 |
+
description: "Securely copy files to remote host",
|
472 |
+
os: ["linux", "macos"],
|
473 |
+
category: "ssh",
|
474 |
+
tags: ["ssh", "copy"],
|
475 |
+
usage: "scp backup.tar.gz [email protected]:/backups/"
|
476 |
+
},
|
477 |
+
{
|
478 |
+
id: 37,
|
479 |
+
command: "rsync -avz source destination",
|
480 |
+
description: "Synchronize files/directories between systems efficiently",
|
481 |
+
os: ["linux", "macos"],
|
482 |
+
category: "ssh",
|
483 |
+
tags: ["sync", "copy"],
|
484 |
+
usage: "rsync -avz /local/dir/ user@remote:/remote/dir/"
|
485 |
+
},
|
486 |
+
|
487 |
+
// System Info
|
488 |
+
{
|
489 |
+
id: 38,
|
490 |
+
command: "uname -a",
|
491 |
+
description: "Show system and kernel information",
|
492 |
+
os: ["linux", "macos"],
|
493 |
+
category: "system",
|
494 |
+
tags: ["system", "info"],
|
495 |
+
usage: "uname -a"
|
496 |
+
},
|
497 |
+
{
|
498 |
+
id: 39,
|
499 |
+
command: "top",
|
500 |
+
description: "Display dynamic real-time information about running processes",
|
501 |
+
os: ["linux", "macos"],
|
502 |
+
category: "system",
|
503 |
+
tags: ["process", "monitoring"],
|
504 |
+
usage: "top"
|
505 |
+
},
|
506 |
+
{
|
507 |
+
id: 40,
|
508 |
+
command: "htop",
|
509 |
+
description: "Interactive process viewer (more user-friendly than top)",
|
510 |
+
os: ["linux", "macos"],
|
511 |
+
category: "system",
|
512 |
+
tags: ["process", "monitoring"],
|
513 |
+
usage: "htop"
|
514 |
+
},
|
515 |
+
{
|
516 |
+
id: 41,
|
517 |
+
command: "free -h",
|
518 |
+
description: "Show memory usage in human-readable format",
|
519 |
+
os: ["linux", "macos"],
|
520 |
+
category: "system",
|
521 |
+
tags: ["memory", "usage"],
|
522 |
+
usage: "free -h"
|
523 |
+
},
|
524 |
+
{
|
525 |
+
id: 42,
|
526 |
+
command: "uptime",
|
527 |
+
description: "Show how long system has been running and load average",
|
528 |
+
os: ["linux", "macos"],
|
529 |
+
category: "system",
|
530 |
+
tags: ["uptime", "load"],
|
531 |
+
usage: "uptime"
|
532 |
+
},
|
533 |
+
{
|
534 |
+
id: 43,
|
535 |
+
command: "whoami",
|
536 |
+
description: "Print current user name",
|
537 |
+
os: ["linux", "macos", "windows"],
|
538 |
+
category: "system",
|
539 |
+
tags: ["user", "info"],
|
540 |
+
usage: "whoami"
|
541 |
+
},
|
542 |
+
{
|
543 |
+
id: 44,
|
544 |
+
command: "history",
|
545 |
+
description: "Show command history",
|
546 |
+
os: ["linux", "macos"],
|
547 |
+
category: "system",
|
548 |
+
tags: ["history", "commands"],
|
549 |
+
usage: "history"
|
550 |
+
},
|
551 |
+
{
|
552 |
+
id: 45,
|
553 |
+
command: "date",
|
554 |
+
description: "Show current date and time",
|
555 |
+
os: ["linux", "macos", "windows"],
|
556 |
+
category: "system",
|
557 |
+
tags: ["date", "time"],
|
558 |
+
usage: "date"
|
559 |
+
},
|
560 |
+
{
|
561 |
+
id: 46,
|
562 |
+
command: "cal",
|
563 |
+
description: "Show calendar",
|
564 |
+
os: ["linux", "macos"],
|
565 |
+
category: "system",
|
566 |
+
tags: ["calendar"],
|
567 |
+
usage: "cal"
|
568 |
+
},
|
569 |
+
{
|
570 |
+
id: 47,
|
571 |
+
command: "lscpu",
|
572 |
+
description: "Display CPU information",
|
573 |
+
os: ["linux", "macos"],
|
574 |
+
category: "system",
|
575 |
+
tags: ["cpu", "hardware"],
|
576 |
+
usage: "lscpu"
|
577 |
+
},
|
578 |
+
{
|
579 |
+
id: 48,
|
580 |
+
command: "lsblk",
|
581 |
+
description: "List block devices (disks and partitions)",
|
582 |
+
os: ["linux", "macos"],
|
583 |
+
category: "system",
|
584 |
+
tags: ["disk", "partitions"],
|
585 |
+
usage: "lsblk"
|
586 |
+
},
|
587 |
+
{
|
588 |
+
id: 49,
|
589 |
+
command: "lspci",
|
590 |
+
description: "List all PCI devices",
|
591 |
+
os: ["linux", "macos"],
|
592 |
+
category: "system",
|
593 |
+
tags: ["hardware", "pci"],
|
594 |
+
usage: "lspci"
|
595 |
+
},
|
596 |
+
{
|
597 |
+
id: 50,
|
598 |
+
command: "lsusb",
|
599 |
+
description: "List USB devices",
|
600 |
+
os: ["linux", "macos"],
|
601 |
+
category: "system",
|
602 |
+
tags: ["hardware", "usb"],
|
603 |
+
usage: "lsusb"
|
604 |
+
},
|
605 |
+
|
606 |
+
// Processes
|
607 |
+
{
|
608 |
+
id: 51,
|
609 |
+
command: "ps aux",
|
610 |
+
description: "List all running processes",
|
611 |
+
os: ["linux", "macos"],
|
612 |
+
category: "process",
|
613 |
+
tags: ["process", "list"],
|
614 |
+
usage: "ps aux"
|
615 |
+
},
|
616 |
+
{
|
617 |
+
id: 52,
|
618 |
+
command: "kill -9 <pid>",
|
619 |
+
description: "Forcefully terminate a process by its process ID",
|
620 |
+
os: ["linux", "macos"],
|
621 |
+
category: "process",
|
622 |
+
tags: ["process", "terminate"],
|
623 |
+
usage: "kill -9 1234"
|
624 |
+
},
|
625 |
+
{
|
626 |
+
id: 53,
|
627 |
+
command: "killall processname",
|
628 |
+
description: "Kill all processes by name",
|
629 |
+
os: ["linux", "macos"],
|
630 |
+
category: "process",
|
631 |
+
tags: ["process", "terminate"],
|
632 |
+
usage: "killall nginx"
|
633 |
+
},
|
634 |
+
{
|
635 |
+
id: 54,
|
636 |
+
command: "pkill -f pattern",
|
637 |
+
description: "Kill processes by matching pattern",
|
638 |
+
os: ["linux", "macos"],
|
639 |
+
category: "process",
|
640 |
+
tags: ["process", "terminate"],
|
641 |
+
usage: "pkill -f \"python script.py\""
|
642 |
+
},
|
643 |
+
{
|
644 |
+
id: 55,
|
645 |
+
command: "bg",
|
646 |
+
description: "Send process to background",
|
647 |
+
os: ["linux", "macos"],
|
648 |
+
category: "process",
|
649 |
+
tags: ["process", "background"],
|
650 |
+
usage: "bg"
|
651 |
+
},
|
652 |
+
{
|
653 |
+
id: 56,
|
654 |
+
command: "fg",
|
655 |
+
description: "Bring background process to foreground",
|
656 |
+
os: ["linux", "macos"],
|
657 |
+
category: "process",
|
658 |
+
tags: ["process", "foreground"],
|
659 |
+
usage: "fg"
|
660 |
+
},
|
661 |
+
{
|
662 |
+
id: 57,
|
663 |
+
command: "jobs",
|
664 |
+
description: "List background jobs",
|
665 |
+
os: ["linux", "macos"],
|
666 |
+
category: "process",
|
667 |
+
tags: ["jobs", "background"],
|
668 |
+
usage: "jobs"
|
669 |
+
},
|
670 |
+
{
|
671 |
+
id: 58,
|
672 |
+
command: "nohup command &",
|
673 |
+
description: "Run command immune to hangups, with output to nohup.out",
|
674 |
+
os: ["linux", "macos"],
|
675 |
+
category: "process",
|
676 |
+
tags: ["process", "background"],
|
677 |
+
usage: "nohup python script.py &"
|
678 |
+
},
|
679 |
+
{
|
680 |
+
id: 59,
|
681 |
+
command: "time command",
|
682 |
+
description: "Measure time taken by command to execute",
|
683 |
+
os: ["linux", "macos"],
|
684 |
+
category: "process",
|
685 |
+
tags: ["time", "performance"],
|
686 |
+
usage: "time ls -lR /"
|
687 |
+
},
|
688 |
+
{
|
689 |
+
id: 60,
|
690 |
+
command: "watch -n 1 command",
|
691 |
+
description: "Execute command repeatedly every second",
|
692 |
+
os: ["linux", "macos"],
|
693 |
+
category: "process",
|
694 |
+
tags: ["monitor", "watch"],
|
695 |
+
usage: "watch -n 1 free -h"
|
696 |
+
},
|
697 |
+
|
698 |
+
// Compression
|
699 |
+
{
|
700 |
+
id: 61,
|
701 |
+
command: "tar -czvf archive.tar.gz dir",
|
702 |
+
description: "Create gzipped tar archive of directory",
|
703 |
+
os: ["linux", "macos"],
|
704 |
+
category: "compression",
|
705 |
+
tags: ["archive", "compress"],
|
706 |
+
usage: "tar -czvf backup.tar.gz /home/user"
|
707 |
+
},
|
708 |
+
{
|
709 |
+
id: 62,
|
710 |
+
command: "tar -xzvf archive.tar.gz",
|
711 |
+
description: "Extract gzipped tar archive",
|
712 |
+
os: ["linux", "macos"],
|
713 |
+
category: "compression",
|
714 |
+
tags: ["extract", "uncompress"],
|
715 |
+
usage: "tar -xzvf backup.tar.gz"
|
716 |
+
},
|
717 |
+
{
|
718 |
+
id: 63,
|
719 |
+
command: "zip -r archive.zip dir",
|
720 |
+
description: "Create zip archive of directory",
|
721 |
+
os: ["linux", "macos", "windows"],
|
722 |
+
category: "compression",
|
723 |
+
tags: ["archive", "compress"],
|
724 |
+
usage: "zip -r project.zip project/"
|
725 |
+
},
|
726 |
+
{
|
727 |
+
id: 64,
|
728 |
+
command: "unzip archive.zip",
|
729 |
+
description: "Extract zip archive",
|
730 |
+
os: ["linux", "macos", "windows"],
|
731 |
+
category: "compression",
|
732 |
+
tags: ["extract", "uncompress"],
|
733 |
+
usage: "unzip backup.zip"
|
734 |
+
},
|
735 |
+
{
|
736 |
+
id: 65,
|
737 |
+
command: "gzip file",
|
738 |
+
description: "Compress file (replaces original with .gz version)",
|
739 |
+
os: ["linux", "macos"],
|
740 |
+
category: "compression",
|
741 |
+
tags: ["compress", "gzip"],
|
742 |
+
usage: "gzip largefile.log"
|
743 |
+
},
|
744 |
+
{
|
745 |
+
id: 66,
|
746 |
+
command: "gunzip file.gz",
|
747 |
+
description: "Decompress .gz file",
|
748 |
+
os: ["linux", "macos"],
|
749 |
+
category: "compression",
|
750 |
+
tags: ["decompress", "gunzip"],
|
751 |
+
usage: "gunzip largefile.log.gz"
|
752 |
+
},
|
753 |
+
|
754 |
+
// Text Processing
|
755 |
+
{
|
756 |
+
id: 67,
|
757 |
+
command: "grep pattern file",
|
758 |
+
description: "Search for pattern in file",
|
759 |
+
os: ["linux", "macos"],
|
760 |
+
category: "text",
|
761 |
+
tags: ["search", "text"],
|
762 |
+
usage: "grep \"error\" logfile.txt"
|
763 |
+
},
|
764 |
+
{
|
765 |
+
id: 68,
|
766 |
+
command: "sed 's/find/replace/g' file",
|
767 |
+
description: "Find and replace text in file",
|
768 |
+
os: ["linux", "macos"],
|
769 |
+
category: "text",
|
770 |
+
tags: ["replace", "text"],
|
771 |
+
usage: "sed 's/foo/bar/g' file.txt"
|
772 |
+
},
|
773 |
+
{
|
774 |
+
id: 69,
|
775 |
+
command: "awk '{print $1}' file",
|
776 |
+
description: "Print first column of file",
|
777 |
+
os: ["linux", "macos"],
|
778 |
+
category: "text",
|
779 |
+
tags: ["text", "processing"],
|
780 |
+
usage: "awk '{print $1}' data.csv"
|
781 |
+
},
|
782 |
+
{
|
783 |
+
id: 70,
|
784 |
+
command: "sort file",
|
785 |
+
description: "Sort lines in file",
|
786 |
+
os: ["linux", "macos"],
|
787 |
+
category: "text",
|
788 |
+
tags: ["sort", "text"],
|
789 |
+
usage: "sort names.txt"
|
790 |
+
},
|
791 |
+
{
|
792 |
+
id: 71,
|
793 |
+
command: "uniq file",
|
794 |
+
description: "Filter adjacent matching lines from file",
|
795 |
+
os: ["linux", "macos"],
|
796 |
+
category: "text",
|
797 |
+
tags: ["unique", "filter"],
|
798 |
+
usage: "uniq duplicates.txt"
|
799 |
+
},
|
800 |
+
{
|
801 |
+
id: 72,
|
802 |
+
command: "cut -d',' -f1 file",
|
803 |
+
description: "Cut first field from comma-delimited file",
|
804 |
+
os: ["linux", "macos"],
|
805 |
+
category: "text",
|
806 |
+
tags: ["cut", "text"],
|
807 |
+
usage: "cut -d',' -f1 data.csv"
|
808 |
+
},
|
809 |
+
{
|
810 |
+
id: 73,
|
811 |
+
command: "tr 'a-z' 'A-Z' < file",
|
812 |
+
description: "Translate characters to uppercase",
|
813 |
+
os: ["linux", "macos"],
|
814 |
+
category: "text",
|
815 |
+
tags: ["translate", "text"],
|
816 |
+
usage: "tr 'a-z' 'A-Z' < file.txt"
|
817 |
+
},
|
818 |
+
{
|
819 |
+
id: 74,
|
820 |
+
command: "tee file",
|
821 |
+
description: "Pipe output to file and stdout",
|
822 |
+
os: ["linux", "macos"],
|
823 |
+
category: "text",
|
824 |
+
tags: ["pipe", "output"],
|
825 |
+
usage: "ls -l | tee directory_listing.txt"
|
826 |
+
},
|
827 |
+
{
|
828 |
+
id: 75,
|
829 |
+
command: "column -t file",
|
830 |
+
description: "Format text into columns",
|
831 |
+
os: ["linux", "macos"],
|
832 |
+
category: "text",
|
833 |
+
tags: ["format", "columns"],
|
834 |
+
usage: "column -t data.txt"
|
835 |
+
},
|
836 |
+
{
|
837 |
+
id: 76,
|
838 |
+
command: "nl file",
|
839 |
+
description: "Number lines in file",
|
840 |
+
os: ["linux", "macos"],
|
841 |
+
category: "text",
|
842 |
+
tags: ["number", "lines"],
|
843 |
+
usage: "nl document.txt"
|
844 |
+
},
|
845 |
+
|
846 |
+
// Git
|
847 |
+
{
|
848 |
+
id: 77,
|
849 |
+
command: "git clone <repository-url>",
|
850 |
+
description: "Clone a remote Git repository to your local machine",
|
851 |
+
os: ["linux", "macos", "windows"],
|
852 |
+
category: "git",
|
853 |
+
tags: ["git", "version control"],
|
854 |
+
usage: "git clone https://github.com/user/repo.git"
|
855 |
+
},
|
856 |
+
{
|
857 |
+
id: 78,
|
858 |
+
command: "git status",
|
859 |
+
description: "Show the working tree status (changed files, staged files, etc.)",
|
860 |
+
os: ["linux", "macos", "windows"],
|
861 |
+
category: "git",
|
862 |
+
tags: ["git", "status"],
|
863 |
+
usage: "git status"
|
864 |
+
},
|
865 |
+
{
|
866 |
+
id: 79,
|
867 |
+
command: "git add .",
|
868 |
+
description: "Add all changed files to staging area",
|
869 |
+
os: ["linux", "macos", "windows"],
|
870 |
+
category: "git",
|
871 |
+
tags: ["git", "add"],
|
872 |
+
usage: "git add ."
|
873 |
+
},
|
874 |
+
{
|
875 |
+
id: 80,
|
876 |
+
command: "git commit -m \"message\"",
|
877 |
+
description: "Commit staged changes with message",
|
878 |
+
os: ["linux", "macos", "windows"],
|
879 |
+
category: "git",
|
880 |
+
tags: ["git", "commit"],
|
881 |
+
usage: "git commit -m \"Fixed login bug\""
|
882 |
+
},
|
883 |
+
{
|
884 |
+
id: 81,
|
885 |
+
command: "git push origin main",
|
886 |
+
description: "Push commits to remote repository",
|
887 |
+
os: ["linux", "macos", "windows"],
|
888 |
+
category: "git",
|
889 |
+
tags: ["git", "push"],
|
890 |
+
usage: "git push origin main"
|
891 |
+
},
|
892 |
+
{
|
893 |
+
id: 82,
|
894 |
+
command: "git pull",
|
895 |
+
description: "Fetch from and integrate with remote repository",
|
896 |
+
os: ["linux", "macos", "windows"],
|
897 |
+
category: "git",
|
898 |
+
tags: ["git", "pull"],
|
899 |
+
usage: "git pull"
|
900 |
+
},
|
901 |
+
{
|
902 |
+
id: 83,
|
903 |
+
command: "git branch",
|
904 |
+
description: "List all branches",
|
905 |
+
os: ["linux", "macos", "windows"],
|
906 |
+
category: "git",
|
907 |
+
tags: ["git", "branch"],
|
908 |
+
usage: "git branch"
|
909 |
+
},
|
910 |
+
{
|
911 |
+
id: 84,
|
912 |
+
command: "git checkout -b new-branch",
|
913 |
+
description: "Create and switch to new branch",
|
914 |
+
os: ["linux", "macos", "windows"],
|
915 |
+
category: "git",
|
916 |
+
tags: ["git", "branch"],
|
917 |
+
usage: "git checkout -b feature/login"
|
918 |
+
},
|
919 |
+
{
|
920 |
+
id: 85,
|
921 |
+
command: "git merge branch",
|
922 |
+
description: "Merge branch into current branch",
|
923 |
+
os: ["linux", "macos", "windows"],
|
924 |
+
category: "git",
|
925 |
+
tags: ["git", "merge"],
|
926 |
+
usage: "git merge feature/login"
|
927 |
+
},
|
928 |
+
{
|
929 |
+
id: 86,
|
930 |
+
command: "git log --oneline",
|
931 |
+
description: "Show commit history in compact format",
|
932 |
+
os: ["linux", "macos", "windows"],
|
933 |
+
category: "git",
|
934 |
+
tags: ["git", "log"],
|
935 |
+
usage: "git log --oneline"
|
936 |
+
},
|
937 |
+
{
|
938 |
+
id: 87,
|
939 |
+
command: "git reset --hard HEAD",
|
940 |
+
description: "Discard all local changes (permanently)",
|
941 |
+
os: ["linux", "macos", "windows"],
|
942 |
+
category: "git",
|
943 |
+
tags: ["git", "reset"],
|
944 |
+
usage: "git reset --hard HEAD"
|
945 |
+
},
|
946 |
+
{
|
947 |
+
id: 88,
|
948 |
+
command: "git stash",
|
949 |
+
description: "Stash changes in dirty working directory",
|
950 |
+
os: ["linux", "macos", "windows"],
|
951 |
+
category: "git",
|
952 |
+
tags: ["git", "stash"],
|
953 |
+
usage: "git stash"
|
954 |
+
},
|
955 |
+
{
|
956 |
+
id: 89,
|
957 |
+
command: "git rebase branch",
|
958 |
+
description: "Reapply commits on top of another branch",
|
959 |
+
os: ["linux", "macos", "windows"],
|
960 |
+
category: "git",
|
961 |
+
tags: ["git", "rebase"],
|
962 |
+
usage: "git rebase main"
|
963 |
+
},
|
964 |
+
{
|
965 |
+
id: 90,
|
966 |
+
command: "git remote -v",
|
967 |
+
description: "List remote repositories",
|
968 |
+
os: ["linux", "macos", "windows"],
|
969 |
+
category: "git",
|
970 |
+
tags: ["git", "remote"],
|
971 |
+
usage: "git remote -v"
|
972 |
+
},
|
973 |
+
|
974 |
+
// Docker
|
975 |
+
{
|
976 |
+
id: 91,
|
977 |
+
command: "docker ps -a",
|
978 |
+
description: "List all Docker containers (both running and stopped)",
|
979 |
+
os: ["linux", "macos", "windows"],
|
980 |
+
category: "docker",
|
981 |
+
tags: ["docker", "containers"],
|
982 |
+
usage: "docker ps -a"
|
983 |
+
},
|
984 |
+
{
|
985 |
+
id: 92,
|
986 |
+
command: "docker images",
|
987 |
+
description: "List all Docker images",
|
988 |
+
os: ["linux", "macos", "windows"],
|
989 |
+
category: "docker",
|
990 |
+
tags: ["docker", "images"],
|
991 |
+
usage: "docker images"
|
992 |
+
},
|
993 |
+
{
|
994 |
+
id: 93,
|
995 |
+
command: "docker run image",
|
996 |
+
description: "Run a command in a new container",
|
997 |
+
os: ["linux", "macos", "windows"],
|
998 |
+
category: "docker",
|
999 |
+
tags: ["docker", "run"],
|
1000 |
+
usage: "docker run -it ubuntu bash"
|
1001 |
+
},
|
1002 |
+
{
|
1003 |
+
id: 94,
|
1004 |
+
command: "docker stop container",
|
1005 |
+
description: "Stop one or more running containers",
|
1006 |
+
os: ["linux", "macos", "windows"],
|
1007 |
+
category: "docker",
|
1008 |
+
tags: ["docker", "stop"],
|
1009 |
+
usage: "docker stop my_container"
|
1010 |
+
},
|
1011 |
+
{
|
1012 |
+
id: 95,
|
1013 |
+
command: "docker rm container",
|
1014 |
+
description: "Remove one or more containers",
|
1015 |
+
os: ["linux", "macos", "windows"],
|
1016 |
+
category: "docker",
|
1017 |
+
tags: ["docker", "remove"],
|
1018 |
+
usage: "docker rm my_container"
|
1019 |
+
},
|
1020 |
+
{
|
1021 |
+
id: 96,
|
1022 |
+
command: "docker rmi image",
|
1023 |
+
description: "Remove one or more images",
|
1024 |
+
os: ["linux", "macos", "windows"],
|
1025 |
+
category: "docker",
|
1026 |
+
tags: ["docker", "remove"],
|
1027 |
+
usage: "docker rmi ubuntu"
|
1028 |
+
},
|
1029 |
+
{
|
1030 |
+
id: 97,
|
1031 |
+
command: "docker exec -it container bash",
|
1032 |
+
description: "Run a command in a running container",
|
1033 |
+
os: ["linux", "macos", "windows"],
|
1034 |
+
category: "docker",
|
1035 |
+
tags: ["docker", "exec"],
|
1036 |
+
usage: "docker exec -it my_container bash"
|
1037 |
+
},
|
1038 |
+
{
|
1039 |
+
id: 98,
|
1040 |
+
command: "docker logs container",
|
1041 |
+
description: "Fetch the logs of a container",
|
1042 |
+
os: ["linux", "macos", "windows"],
|
1043 |
+
category: "docker",
|
1044 |
+
tags: ["docker", "logs"],
|
1045 |
+
usage: "docker logs my_container"
|
1046 |
+
},
|
1047 |
+
{
|
1048 |
+
id: 99,
|
1049 |
+
command: "docker build -t name .",
|
1050 |
+
description: "Build an image from a Dockerfile",
|
1051 |
+
os: ["linux", "macos", "windows"],
|
1052 |
+
category: "docker",
|
1053 |
+
tags: ["docker", "build"],
|
1054 |
+
usage: "docker build -t my_image ."
|
1055 |
+
},
|
1056 |
+
{
|
1057 |
+
id: 100,
|
1058 |
+
command: "docker-compose up -d",
|
1059 |
+
description: "Start Docker containers in detached mode using docker-compose",
|
1060 |
+
os: ["linux", "macos", "windows"],
|
1061 |
+
category: "docker",
|
1062 |
+
tags: ["docker", "compose"],
|
1063 |
+
usage: "docker-compose up -d"
|
1064 |
+
},
|
1065 |
+
{
|
1066 |
+
id: 101,
|
1067 |
+
command: "docker-compose down",
|
1068 |
+
description: "Stop and remove containers, networks, images, and volumes",
|
1069 |
+
os: ["linux", "macos", "windows"],
|
1070 |
+
category: "docker",
|
1071 |
+
tags: ["docker", "compose"],
|
1072 |
+
usage: "docker-compose down"
|
1073 |
+
},
|
1074 |
+
{
|
1075 |
+
id: 102,
|
1076 |
+
command: "docker volume ls",
|
1077 |
+
description: "List volumes",
|
1078 |
+
os: ["linux", "macos", "windows"],
|
1079 |
+
category: "docker",
|
1080 |
+
tags: ["docker", "volumes"],
|
1081 |
+
usage: "docker volume ls"
|
1082 |
+
},
|
1083 |
+
{
|
1084 |
+
id: 103,
|
1085 |
+
command: "docker network ls",
|
1086 |
+
description: "List networks",
|
1087 |
+
os: ["linux", "macos", "windows"],
|
1088 |
+
category: "docker",
|
1089 |
+
tags: ["docker", "networks"],
|
1090 |
+
usage: "docker network ls"
|
1091 |
+
},
|
1092 |
+
{
|
1093 |
+
id: 104,
|
1094 |
+
command: "docker system prune",
|
1095 |
+
description: "Remove unused data",
|
1096 |
+
os: ["linux", "macos", "windows"],
|
1097 |
+
category: "docker",
|
1098 |
+
tags: ["docker", "cleanup"],
|
1099 |
+
usage: "docker system prune"
|
1100 |
+
},
|
1101 |
+
{
|
1102 |
+
id: 105,
|
1103 |
+
command: "docker inspect container",
|
1104 |
+
description: "Return low-level information on Docker objects",
|
1105 |
+
os: ["linux", "macos", "windows"],
|
1106 |
+
category: "docker",
|
1107 |
+
tags: ["docker", "inspect"],
|
1108 |
+
usage: "docker inspect my_container"
|
1109 |
+
},
|
1110 |
+
|
1111 |
+
// Package Managers
|
1112 |
+
{
|
1113 |
+
id: 106,
|
1114 |
+
command: "apt update",
|
1115 |
+
description: "Refresh package index (Debian/Ubuntu)",
|
1116 |
+
os: ["linux"],
|
1117 |
+
category: "package",
|
1118 |
+
tags: ["apt", "update"],
|
1119 |
+
usage: "apt update"
|
1120 |
+
},
|
1121 |
+
{
|
1122 |
+
id: 107,
|
1123 |
+
command: "apt install package",
|
1124 |
+
description: "Install package (Debian/Ubuntu)",
|
1125 |
+
os: ["linux"],
|
1126 |
+
category: "package",
|
1127 |
+
tags: ["apt", "install"],
|
1128 |
+
usage: "apt install nginx"
|
1129 |
+
},
|
1130 |
+
{
|
1131 |
+
id: 108,
|
1132 |
+
command: "apt remove package",
|
1133 |
+
description: "Remove package (Debian/Ubuntu)",
|
1134 |
+
os: ["linux"],
|
1135 |
+
category: "package",
|
1136 |
+
tags: ["apt", "remove"],
|
1137 |
+
usage: "apt remove nginx"
|
1138 |
+
},
|
1139 |
+
{
|
1140 |
+
id: 109,
|
1141 |
+
command: "apt upgrade",
|
1142 |
+
description: "Upgrade all upgradable packages (Debian/Ubuntu)",
|
1143 |
+
os: ["linux"],
|
1144 |
+
category: "package",
|
1145 |
+
tags: ["apt", "upgrade"],
|
1146 |
+
usage: "apt upgrade"
|
1147 |
+
},
|
1148 |
+
{
|
1149 |
+
id: 110,
|
1150 |
+
command: "yum install package",
|
1151 |
+
description: "Install package (RHEL/CentOS)",
|
1152 |
+
os: ["linux"],
|
1153 |
+
category: "package",
|
1154 |
+
tags: ["yum", "install"],
|
1155 |
+
usage: "yum install httpd"
|
1156 |
+
},
|
1157 |
+
{
|
1158 |
+
id: 111,
|
1159 |
+
command: "yum remove package",
|
1160 |
+
description: "Remove package (RHEL/CentOS)",
|
1161 |
+
os: ["linux"],
|
1162 |
+
category: "package",
|
1163 |
+
tags: ["yum", "remove"],
|
1164 |
+
usage: "yum remove httpd"
|
1165 |
+
},
|
1166 |
+
{
|
1167 |
+
id: 112,
|
1168 |
+
command: "yum update",
|
1169 |
+
description: "Update all packages (RHEL/CentOS)",
|
1170 |
+
os: ["linux"],
|
1171 |
+
category: "package",
|
1172 |
+
tags: ["yum", "update"],
|
1173 |
+
usage: "yum update"
|
1174 |
+
},
|
1175 |
+
{
|
1176 |
+
id: 113,
|
1177 |
+
command: "dnf install package",
|
1178 |
+
description: "Install package (Fedora)",
|
1179 |
+
os: ["linux"],
|
1180 |
+
category: "package",
|
1181 |
+
tags: ["dnf", "install"],
|
1182 |
+
usage: "dnf install nginx"
|
1183 |
+
},
|
1184 |
+
{
|
1185 |
+
id: 114,
|
1186 |
+
command: "pacman -S package",
|
1187 |
+
description: "Install package (Arch Linux)",
|
1188 |
+
os: ["linux"],
|
1189 |
+
category: "package",
|
1190 |
+
tags: ["pacman", "install"],
|
1191 |
+
usage: "pacman -S firefox"
|
1192 |
+
},
|
1193 |
+
{
|
1194 |
+
id: 115,
|
1195 |
+
command: "brew install package",
|
1196 |
+
description: "Install package (macOS)",
|
1197 |
+
os: ["macos"],
|
1198 |
+
category: "package",
|
1199 |
+
tags: ["brew", "install"],
|
1200 |
+
usage: "brew install wget"
|
1201 |
+
},
|
1202 |
+
{
|
1203 |
+
id: 116,
|
1204 |
+
command: "brew upgrade package",
|
1205 |
+
description: "Upgrade package (macOS)",
|
1206 |
+
os: ["macos"],
|
1207 |
+
category: "package",
|
1208 |
+
tags: ["brew", "upgrade"],
|
1209 |
+
usage: "brew upgrade wget"
|
1210 |
+
},
|
1211 |
+
{
|
1212 |
+
id: 117,
|
1213 |
+
command: "npm install package",
|
1214 |
+
description: "Install Node.js package",
|
1215 |
+
os: ["linux", "macos", "windows"],
|
1216 |
+
category: "package",
|
1217 |
+
tags: ["npm", "install"],
|
1218 |
+
usage: "npm install express"
|
1219 |
+
},
|
1220 |
+
{
|
1221 |
+
id: 118,
|
1222 |
+
command: "pip install package",
|
1223 |
+
description: "Install Python package",
|
1224 |
+
os: ["linux", "macos", "windows"],
|
1225 |
+
category: "package",
|
1226 |
+
tags: ["pip", "install"],
|
1227 |
+
usage: "pip install requests"
|
1228 |
+
},
|
1229 |
+
|
1230 |
+
// Windows Specific
|
1231 |
+
{
|
1232 |
+
id: 119,
|
1233 |
+
command: "dir",
|
1234 |
+
description: "List directory contents (Windows)",
|
1235 |
+
os: ["windows"],
|
1236 |
+
category: "file",
|
1237 |
+
tags: ["list", "directory"],
|
1238 |
+
usage: "dir C:\\"
|
1239 |
+
},
|
1240 |
+
{
|
1241 |
+
id: 120,
|
1242 |
+
command: "tasklist",
|
1243 |
+
description: "Display all currently running processes (Windows)",
|
1244 |
+
os: ["windows"],
|
1245 |
+
category: "process",
|
1246 |
+
tags: ["process", "windows"],
|
1247 |
+
usage: "tasklist"
|
1248 |
+
},
|
1249 |
+
{
|
1250 |
+
id: 121,
|
1251 |
+
command: "taskkill /PID pid /F",
|
1252 |
+
description: "Forcefully terminate a process by PID (Windows)",
|
1253 |
+
os: ["windows"],
|
1254 |
+
category: "process",
|
1255 |
+
tags: ["process", "terminate"],
|
1256 |
+
usage: "taskkill /PID 1234 /F"
|
1257 |
+
},
|
1258 |
+
{
|
1259 |
+
id: 122,
|
1260 |
+
command: "systeminfo",
|
1261 |
+
description: "Display detailed system configuration (Windows)",
|
1262 |
+
os: ["windows"],
|
1263 |
+
category: "system",
|
1264 |
+
tags: ["system", "info"],
|
1265 |
+
usage: "systeminfo"
|
1266 |
+
},
|
1267 |
+
{
|
1268 |
+
id: 123,
|
1269 |
+
command: "sfc /scannow",
|
1270 |
+
description: "System File Checker - scans and repairs system files (Windows)",
|
1271 |
+
os: ["windows"],
|
1272 |
+
category: "system",
|
1273 |
+
tags: ["repair", "system"],
|
1274 |
+
usage: "sfc /scannow"
|
1275 |
+
},
|
1276 |
+
{
|
1277 |
+
id: 124,
|
1278 |
+
command: "chkdsk /f",
|
1279 |
+
description: "Check disk for errors and fix them (Windows)",
|
1280 |
+
os: ["windows"],
|
1281 |
+
category: "system",
|
1282 |
+
tags: ["disk", "repair"],
|
1283 |
+
usage: "chkdsk C: /f"
|
1284 |
+
},
|
1285 |
+
{
|
1286 |
+
id: 125,
|
1287 |
+
command: "net user",
|
1288 |
+
description: "Manage user accounts (Windows)",
|
1289 |
+
os: ["windows"],
|
1290 |
+
category: "system",
|
1291 |
+
tags: ["user", "accounts"],
|
1292 |
+
usage: "net user username password /add"
|
1293 |
+
},
|
1294 |
+
{
|
1295 |
+
id: 126,
|
1296 |
+
command: "shutdown /s /t 0",
|
1297 |
+
description: "Shutdown computer immediately (Windows)",
|
1298 |
+
os: ["windows"],
|
1299 |
+
category: "system",
|
1300 |
+
tags: ["shutdown", "power"],
|
1301 |
+
usage: "shutdown /s /t 0"
|
1302 |
+
},
|
1303 |
+
{
|
1304 |
+
id: 127,
|
1305 |
+
command: "mklink /D link target",
|
1306 |
+
description: "Create symbolic link (Windows)",
|
1307 |
+
os: ["windows"],
|
1308 |
+
category: "file",
|
1309 |
+
tags: ["link", "symlink"],
|
1310 |
+
usage: "mklink /D C:\\link C:\\target"
|
1311 |
+
},
|
1312 |
+
{
|
1313 |
+
id: 128,
|
1314 |
+
command: "robocopy source destination /MIR",
|
1315 |
+
description: "Robust file copy with mirror option (Windows)",
|
1316 |
+
os: ["windows"],
|
1317 |
+
category: "file",
|
1318 |
+
tags: ["copy", "files"],
|
1319 |
+
usage: "robocopy C:\\source D:\\backup /MIR"
|
1320 |
+
}
|
1321 |
+
];
|
1322 |
+
|
1323 |
+
// DOM elements
|
1324 |
+
const commandsContainer = document.getElementById('commandsContainer');
|
1325 |
+
const searchInput = document.getElementById('searchInput');
|
1326 |
+
const osFilter = document.getElementById('osFilter');
|
1327 |
+
const categoryFilter = document.getElementById('categoryFilter');
|
1328 |
+
const emptyState = document.getElementById('emptyState');
|
1329 |
+
const toast = document.getElementById('toast');
|
1330 |
+
const totalCommandsEl = document.getElementById('totalCommands');
|
1331 |
+
const linuxCountEl = document.getElementById('linuxCount');
|
1332 |
+
const macosCountEl = document.getElementById('macosCount');
|
1333 |
+
const windowsCountEl = document.getElementById('windowsCount');
|
1334 |
+
const popularTags = document.getElementById('popularTags');
|
1335 |
+
|
1336 |
+
// Category colors
|
1337 |
+
const categoryColors = {
|
1338 |
+
file: 'bg-blue-100 text-blue-800',
|
1339 |
+
network: 'bg-green-100 text-green-800',
|
1340 |
+
system: 'bg-purple-100 text-purple-800',
|
1341 |
+
process: 'bg-red-100 text-red-800',
|
1342 |
+
git: 'bg-orange-100 text-orange-800',
|
1343 |
+
docker: 'bg-indigo-100 text-indigo-800',
|
1344 |
+
permissions: 'bg-yellow-100 text-yellow-800',
|
1345 |
+
compression: 'bg-pink-100 text-pink-800',
|
1346 |
+
text: 'bg-teal-100 text-teal-800',
|
1347 |
+
package: 'bg-gray-100 text-gray-800',
|
1348 |
+
ssh: 'bg-cyan-100 text-cyan-800'
|
1349 |
+
};
|
1350 |
+
|
1351 |
+
// Initialize
|
1352 |
+
function init() {
|
1353 |
+
renderCommands(commands);
|
1354 |
+
updateStats();
|
1355 |
+
|
1356 |
+
// Event listeners
|
1357 |
+
searchInput.addEventListener('input', filterCommands);
|
1358 |
+
osFilter.addEventListener('change', filterCommands);
|
1359 |
+
categoryFilter.addEventListener('change', filterCommands);
|
1360 |
+
|
1361 |
+
// Tag click events
|
1362 |
+
popularTags.addEventListener('click', (e) => {
|
1363 |
+
if (e.target.tagName === 'BUTTON') {
|
1364 |
+
const tag = e.target.getAttribute('data-tag');
|
1365 |
+
searchInput.value = tag;
|
1366 |
+
filterCommands();
|
1367 |
+
}
|
1368 |
+
});
|
1369 |
+
}
|
1370 |
+
|
1371 |
+
// Render commands
|
1372 |
+
function renderCommands(commandsToRender) {
|
1373 |
+
commandsContainer.innerHTML = '';
|
1374 |
+
|
1375 |
+
if (commandsToRender.length === 0) {
|
1376 |
+
emptyState.classList.remove('hidden');
|
1377 |
+
return;
|
1378 |
+
}
|
1379 |
+
|
1380 |
+
emptyState.classList.add('hidden');
|
1381 |
+
|
1382 |
+
commandsToRender.forEach(cmd => {
|
1383 |
+
const osIcons = {
|
1384 |
+
linux: 'fab fa-linux',
|
1385 |
+
macos: 'fab fa-apple',
|
1386 |
+
windows: 'fab fa-windows'
|
1387 |
+
};
|
1388 |
+
|
1389 |
+
const osBadges = cmd.os.map(os => `
|
1390 |
+
<span class="inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-gray-100 text-gray-800">
|
1391 |
+
<i class="${osIcons[os]} mr-1"></i> ${os}
|
1392 |
+
</span>
|
1393 |
+
`).join(' ');
|
1394 |
+
|
1395 |
+
const tags = cmd.tags.map(tag => `
|
1396 |
+
<span class="inline-block bg-gray-100 rounded-full px-2 py-1 text-xs font-medium text-gray-700">${tag}</span>
|
1397 |
+
`).join(' ');
|
1398 |
+
|
1399 |
+
const commandCard = document.createElement('div');
|
1400 |
+
commandCard.className = 'command-card bg-white rounded-xl shadow-md overflow-hidden hover:shadow-lg cursor-pointer relative';
|
1401 |
+
commandCard.innerHTML = `
|
1402 |
+
<div class="category-badge ${categoryColors[cmd.category]}">${cmd.category}</div>
|
1403 |
+
<div class="p-6">
|
1404 |
+
<div class="flex justify-between items-start">
|
1405 |
+
<div class="flex-1">
|
1406 |
+
<h3 class="text-lg font-medium text-gray-900 mb-1 command-text">${cmd.command}</h3>
|
1407 |
+
<div class="flex flex-wrap gap-1 mb-3">${osBadges}</div>
|
1408 |
+
</div>
|
1409 |
+
<button class="copy-btn ml-2 p-2 text-gray-400 hover:text-indigo-600 rounded-full hover:bg-indigo-50" data-command="${cmd.usage || cmd.command}">
|
1410 |
+
<i class="far fa-copy"></i>
|
1411 |
+
</button>
|
1412 |
+
</div>
|
1413 |
+
<p class="text-gray-600 mb-3 description-text">${cmd.description}</p>
|
1414 |
+
${cmd.usage ? `
|
1415 |
+
<div class="bg-gray-50 p-3 rounded-md mb-3">
|
1416 |
+
<p class="text-xs text-gray-500 mb-1">Usage example:</p>
|
1417 |
+
<code class="text-sm text-gray-800 usage-text">${cmd.usage}</code>
|
1418 |
+
</div>
|
1419 |
+
` : ''}
|
1420 |
+
<div class="flex flex-wrap gap-1">${tags}</div>
|
1421 |
+
</div>
|
1422 |
+
`;
|
1423 |
+
|
1424 |
+
// Add click event to copy command
|
1425 |
+
const copyBtn = commandCard.querySelector('.copy-btn');
|
1426 |
+
copyBtn.addEventListener('click', (e) => {
|
1427 |
+
e.stopPropagation();
|
1428 |
+
copyToClipboard(copyBtn.getAttribute('data-command'));
|
1429 |
+
});
|
1430 |
+
|
1431 |
+
// Click anywhere on card to copy main command
|
1432 |
+
commandCard.addEventListener('click', () => {
|
1433 |
+
copyToClipboard(cmd.usage || cmd.command);
|
1434 |
+
});
|
1435 |
+
|
1436 |
+
commandsContainer.appendChild(commandCard);
|
1437 |
+
});
|
1438 |
+
}
|
1439 |
+
|
1440 |
+
// Filter commands based on search and filters
|
1441 |
+
function filterCommands() {
|
1442 |
+
const searchTerm = searchInput.value.toLowerCase();
|
1443 |
+
const osFilterValue = osFilter.value;
|
1444 |
+
const categoryFilterValue = categoryFilter.value;
|
1445 |
+
|
1446 |
+
let filtered = commands.filter(cmd => {
|
1447 |
+
// OS filter
|
1448 |
+
if (osFilterValue !== 'all' && !cmd.os.includes(osFilterValue)) {
|
1449 |
+
return false;
|
1450 |
+
}
|
1451 |
+
|
1452 |
+
// Category filter
|
1453 |
+
if (categoryFilterValue !== 'all' && cmd.category !== categoryFilterValue) {
|
1454 |
+
return false;
|
1455 |
+
}
|
1456 |
+
|
1457 |
+
// Search term
|
1458 |
+
if (searchTerm) {
|
1459 |
+
const inCommand = cmd.command.toLowerCase().includes(searchTerm);
|
1460 |
+
const inDescription = cmd.description.toLowerCase().includes(searchTerm);
|
1461 |
+
const inTags = cmd.tags.some(tag => tag.toLowerCase().includes(searchTerm));
|
1462 |
+
const inUsage = cmd.usage ? cmd.usage.toLowerCase().includes(searchTerm) : false;
|
1463 |
+
|
1464 |
+
if (!inCommand && !inDescription && !inTags && !inUsage) {
|
1465 |
+
return false;
|
1466 |
+
}
|
1467 |
+
}
|
1468 |
+
|
1469 |
+
return true;
|
1470 |
+
});
|
1471 |
+
|
1472 |
+
// Highlight search terms in the results
|
1473 |
+
if (searchTerm) {
|
1474 |
+
filtered = filtered.map(cmd => {
|
1475 |
+
const regex = new RegExp(searchTerm, 'gi');
|
1476 |
+
|
1477 |
+
// Clone the object to avoid modifying the original
|
1478 |
+
const highlightedCmd = {...cmd};
|
1479 |
+
|
1480 |
+
// Highlight in command
|
1481 |
+
highlightedCmd.command = cmd.command.replace(regex, match =>
|
1482 |
+
`<span class="search-highlight">${match}</span>`
|
1483 |
+
);
|
1484 |
+
|
1485 |
+
// Highlight in description
|
1486 |
+
highlightedCmd.description = cmd.description.replace(regex, match =>
|
1487 |
+
`<span class="search-highlight">${match}</span>`
|
1488 |
+
);
|
1489 |
+
|
1490 |
+
// Highlight in usage if exists
|
1491 |
+
if (cmd.usage) {
|
1492 |
+
highlightedCmd.usage = cmd.usage.replace(regex, match =>
|
1493 |
+
`<span class="search-highlight">${match}</span>`
|
1494 |
+
);
|
1495 |
+
}
|
1496 |
+
|
1497 |
+
return highlightedCmd;
|
1498 |
+
});
|
1499 |
+
}
|
1500 |
+
|
1501 |
+
renderCommands(filtered);
|
1502 |
+
}
|
1503 |
+
|
1504 |
+
// Copy text to clipboard
|
1505 |
+
function copyToClipboard(text) {
|
1506 |
+
navigator.clipboard.writeText(text).then(() => {
|
1507 |
+
showToast();
|
1508 |
+
});
|
1509 |
+
}
|
1510 |
+
|
1511 |
+
// Show toast notification
|
1512 |
+
function showToast() {
|
1513 |
+
toast.classList.remove('translate-y-10', 'opacity-0');
|
1514 |
+
toast.classList.add('translate-y-0', 'opacity-100');
|
1515 |
+
|
1516 |
+
setTimeout(() => {
|
1517 |
+
toast.classList.remove('translate-y-0', 'opacity-100');
|
1518 |
+
toast.classList.add('translate-y-10', 'opacity-0');
|
1519 |
+
}, 2000);
|
1520 |
+
}
|
1521 |
+
|
1522 |
+
// Update statistics
|
1523 |
+
function updateStats() {
|
1524 |
+
totalCommandsEl.textContent = commands.length;
|
1525 |
+
linuxCountEl.textContent = commands.filter(cmd => cmd.os.includes('linux')).length;
|
1526 |
+
macosCountEl.textContent = commands.filter(cmd => cmd.os.includes('macos')).length;
|
1527 |
+
windowsCountEl.textContent = commands.filter(cmd => cmd.os.includes('windows')).length;
|
1528 |
+
}
|
1529 |
+
|
1530 |
+
// Initialize the app
|
1531 |
+
init();
|
1532 |
+
</script>
|
1533 |
+
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=DouglasMourray/searchable-library-of-terminal-commands" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
|
1534 |
+
</html>
|
prompts.txt
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
Create a searchable library with ALL terminal commands. Add an input field where you can enter your username and make the command examples fetch it so it makes usable examples.
|