machineconfig 5.29__py3-none-any.whl → 5.30__py3-none-any.whl
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.
Potentially problematic release.
This version of machineconfig might be problematic. Click here for more details.
- machineconfig/scripts/python/devops_helpers/devops_status.py +118 -55
- machineconfig/scripts/python/helpers_repos/grource.py +2 -3
- machineconfig/scripts/windows/select_pwsh_theme.ps1 +44 -0
- machineconfig/settings/linters/.ruff.toml +1 -1
- machineconfig/settings/shells/pwsh/init.ps1 +1 -1
- machineconfig/setup_windows/uv.ps1 +1 -1
- machineconfig/setup_windows/web_shortcuts/interactive.ps1 +2 -3
- machineconfig/utils/installer_utils/installer_class.py +3 -5
- {machineconfig-5.29.dist-info → machineconfig-5.30.dist-info}/METADATA +1 -1
- {machineconfig-5.29.dist-info → machineconfig-5.30.dist-info}/RECORD +13 -12
- {machineconfig-5.29.dist-info → machineconfig-5.30.dist-info}/WHEEL +0 -0
- {machineconfig-5.29.dist-info → machineconfig-5.30.dist-info}/entry_points.txt +0 -0
- {machineconfig-5.29.dist-info → machineconfig-5.30.dist-info}/top_level.txt +0 -0
|
@@ -40,9 +40,10 @@ def _check_shell_profile_status() -> dict[str, Any]:
|
|
|
40
40
|
|
|
41
41
|
try:
|
|
42
42
|
profile_path = get_shell_profile_path()
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
43
|
+
if not profile_path.exists():
|
|
44
|
+
profile_path.parent.mkdir(parents=True, exist_ok=True)
|
|
45
|
+
profile_path.touch()
|
|
46
|
+
profile_content = profile_path.read_text(encoding="utf-8")
|
|
46
47
|
system_name = platform.system()
|
|
47
48
|
if system_name == "Windows":
|
|
48
49
|
init_script = PathExtended(LIBRARY_ROOT).joinpath("settings/shells/pwsh/init.ps1")
|
|
@@ -60,14 +61,22 @@ def _check_shell_profile_status() -> dict[str, Any]:
|
|
|
60
61
|
|
|
61
62
|
return {
|
|
62
63
|
"profile_path": str(profile_path),
|
|
63
|
-
"exists":
|
|
64
|
+
"exists": True,
|
|
64
65
|
"configured": configured,
|
|
65
66
|
"method": method,
|
|
66
67
|
"init_script_exists": init_script.exists(),
|
|
67
68
|
"init_script_copy_exists": init_script_copy.exists(),
|
|
68
69
|
}
|
|
69
70
|
except Exception as ex:
|
|
70
|
-
return {
|
|
71
|
+
return {
|
|
72
|
+
"profile_path": "Error",
|
|
73
|
+
"exists": False,
|
|
74
|
+
"configured": False,
|
|
75
|
+
"method": "error",
|
|
76
|
+
"error": str(ex),
|
|
77
|
+
"init_script_exists": False,
|
|
78
|
+
"init_script_copy_exists": False,
|
|
79
|
+
}
|
|
71
80
|
|
|
72
81
|
|
|
73
82
|
def _check_machineconfig_repo() -> dict[str, Any]:
|
|
@@ -116,7 +125,16 @@ def _check_repos_status() -> dict[str, Any]:
|
|
|
116
125
|
import git
|
|
117
126
|
|
|
118
127
|
repo = git.Repo(str(repo_path))
|
|
119
|
-
repos_info.append(
|
|
128
|
+
repos_info.append(
|
|
129
|
+
{
|
|
130
|
+
"path": str(repo_path),
|
|
131
|
+
"name": repo_path.name,
|
|
132
|
+
"exists": True,
|
|
133
|
+
"is_repo": True,
|
|
134
|
+
"clean": not repo.is_dirty(untracked_files=True),
|
|
135
|
+
"branch": repo.active_branch.name if not repo.head.is_detached else "DETACHED",
|
|
136
|
+
}
|
|
137
|
+
)
|
|
120
138
|
except Exception:
|
|
121
139
|
repos_info.append({"path": str(repo_path), "name": repo_path.name, "exists": True, "is_repo": False})
|
|
122
140
|
|
|
@@ -134,7 +152,15 @@ def _check_ssh_status() -> dict[str, Any]:
|
|
|
134
152
|
keys = []
|
|
135
153
|
for pub_key in ssh_dir.glob("*.pub"):
|
|
136
154
|
private_key = pub_key.with_suffix("")
|
|
137
|
-
keys.append(
|
|
155
|
+
keys.append(
|
|
156
|
+
{
|
|
157
|
+
"name": pub_key.stem,
|
|
158
|
+
"public_exists": True,
|
|
159
|
+
"private_exists": private_key.exists(),
|
|
160
|
+
"public_path": str(pub_key),
|
|
161
|
+
"private_path": str(private_key),
|
|
162
|
+
}
|
|
163
|
+
)
|
|
138
164
|
|
|
139
165
|
config_file = ssh_dir.joinpath("config")
|
|
140
166
|
authorized_keys = ssh_dir.joinpath("authorized_keys")
|
|
@@ -187,13 +213,21 @@ def _check_config_files_status() -> dict[str, Any]:
|
|
|
187
213
|
"private_configs": private_configs,
|
|
188
214
|
}
|
|
189
215
|
except Exception as ex:
|
|
190
|
-
return {
|
|
216
|
+
return {
|
|
217
|
+
"public_count": 0,
|
|
218
|
+
"public_linked": 0,
|
|
219
|
+
"private_count": 0,
|
|
220
|
+
"private_linked": 0,
|
|
221
|
+
"error": str(ex),
|
|
222
|
+
"public_configs": [],
|
|
223
|
+
"private_configs": [],
|
|
224
|
+
}
|
|
191
225
|
|
|
192
226
|
|
|
193
227
|
def _check_important_tools() -> dict[str, dict[str, bool]]:
|
|
194
228
|
"""Check if important CLI tools are installed, organized by groups."""
|
|
195
229
|
from machineconfig.jobs.installer.package_groups import PACKAGE_GROUP2NAMES
|
|
196
|
-
|
|
230
|
+
|
|
197
231
|
group_status = {}
|
|
198
232
|
for group_name, tools in PACKAGE_GROUP2NAMES.items():
|
|
199
233
|
tool_status = {}
|
|
@@ -257,25 +291,33 @@ def _display_shell_status(status: dict[str, Any]) -> None:
|
|
|
257
291
|
return
|
|
258
292
|
|
|
259
293
|
from rich.columns import Columns
|
|
260
|
-
|
|
294
|
+
|
|
261
295
|
left_table = Table(show_header=False, box=None, padding=(0, 1))
|
|
262
296
|
left_table.add_column("Item", style="cyan", no_wrap=True)
|
|
263
297
|
left_table.add_column("Status")
|
|
264
|
-
|
|
265
|
-
left_table.add_row("📄 Profile", status[
|
|
266
|
-
left_table.add_row(f"{'✅' if status['exists'] else '❌'} Exists", str(status[
|
|
267
|
-
left_table.add_row(f"{'✅' if status['configured'] else '❌'} Configured", str(status[
|
|
268
|
-
|
|
298
|
+
|
|
299
|
+
left_table.add_row("📄 Profile", status["profile_path"])
|
|
300
|
+
left_table.add_row(f"{'✅' if status['exists'] else '❌'} Exists", str(status["exists"]))
|
|
301
|
+
left_table.add_row(f"{'✅' if status['configured'] else '❌'} Configured", str(status["configured"]))
|
|
302
|
+
|
|
269
303
|
right_table = Table(show_header=False, box=None, padding=(0, 1))
|
|
270
304
|
right_table.add_column("Item", style="cyan", no_wrap=True)
|
|
271
305
|
right_table.add_column("Status")
|
|
272
|
-
|
|
273
|
-
right_table.add_row("🔧 Method", status[
|
|
274
|
-
right_table.add_row(f"{'✅' if status['init_script_exists'] else '❌'} Init (source)", str(status[
|
|
275
|
-
right_table.add_row(f"{'✅' if status['init_script_copy_exists'] else '❌'} Init (copy)", str(status[
|
|
306
|
+
|
|
307
|
+
right_table.add_row("🔧 Method", status["method"])
|
|
308
|
+
right_table.add_row(f"{'✅' if status['init_script_exists'] else '❌'} Init (source)", str(status["init_script_exists"]))
|
|
309
|
+
right_table.add_row(f"{'✅' if status['init_script_copy_exists'] else '❌'} Init (copy)", str(status["init_script_copy_exists"]))
|
|
276
310
|
|
|
277
311
|
border_style = "green" if status["configured"] else "yellow"
|
|
278
|
-
console.print(
|
|
312
|
+
console.print(
|
|
313
|
+
Panel(
|
|
314
|
+
Columns([left_table, right_table], equal=True, expand=True),
|
|
315
|
+
title="Shell Profile",
|
|
316
|
+
border_style=border_style,
|
|
317
|
+
padding=(1, 2),
|
|
318
|
+
expand=False,
|
|
319
|
+
)
|
|
320
|
+
)
|
|
279
321
|
|
|
280
322
|
|
|
281
323
|
def _display_machineconfig_repo(info: dict[str, Any]) -> None:
|
|
@@ -283,22 +325,38 @@ def _display_machineconfig_repo(info: dict[str, Any]) -> None:
|
|
|
283
325
|
console.rule("[bold magenta]📦 Machineconfig Repository[/bold magenta]")
|
|
284
326
|
|
|
285
327
|
if not info["exists"]:
|
|
286
|
-
console.print(
|
|
328
|
+
console.print(
|
|
329
|
+
Panel(
|
|
330
|
+
"❌ Machineconfig repository not found at ~/code/machineconfig",
|
|
331
|
+
title="Repository Status",
|
|
332
|
+
border_style="red",
|
|
333
|
+
padding=(1, 2),
|
|
334
|
+
expand=False,
|
|
335
|
+
)
|
|
336
|
+
)
|
|
287
337
|
return
|
|
288
338
|
|
|
289
339
|
if not info["is_repo"]:
|
|
290
|
-
console.print(
|
|
340
|
+
console.print(
|
|
341
|
+
Panel(
|
|
342
|
+
f"❌ Directory exists but is not a git repository\n{info.get('error', 'Unknown error')}",
|
|
343
|
+
title="Repository Status",
|
|
344
|
+
border_style="red",
|
|
345
|
+
padding=(1, 2),
|
|
346
|
+
expand=False,
|
|
347
|
+
)
|
|
348
|
+
)
|
|
291
349
|
return
|
|
292
350
|
|
|
293
351
|
table = Table(show_header=False, box=None, padding=(0, 1), expand=False)
|
|
294
352
|
table.add_column("Property", style="cyan", no_wrap=True)
|
|
295
353
|
table.add_column("Value", style="white")
|
|
296
|
-
|
|
297
|
-
table.add_row("📁 Path", info[
|
|
298
|
-
table.add_row("🌿 Branch", info[
|
|
299
|
-
table.add_row("🔖 Commit", info[
|
|
300
|
-
table.add_row(f"{'✅' if info['clean'] else '⚠️'} Status",
|
|
301
|
-
table.add_row("📡 Remotes",
|
|
354
|
+
|
|
355
|
+
table.add_row("📁 Path", info["path"])
|
|
356
|
+
table.add_row("🌿 Branch", info["branch"])
|
|
357
|
+
table.add_row("🔖 Commit", info["commit"])
|
|
358
|
+
table.add_row(f"{'✅' if info['clean'] else '⚠️'} Status", "Clean" if info["clean"] else "Uncommitted changes")
|
|
359
|
+
table.add_row("📡 Remotes", ", ".join(info["remotes"]) if info["remotes"] else "None")
|
|
302
360
|
|
|
303
361
|
border_style = "green" if info["clean"] else "yellow"
|
|
304
362
|
console.print(Panel(table, title="Machineconfig Repository", border_style=border_style, padding=(1, 2), expand=False))
|
|
@@ -344,15 +402,15 @@ def _display_ssh_status(status: dict[str, Any]) -> None:
|
|
|
344
402
|
return
|
|
345
403
|
|
|
346
404
|
from rich.columns import Columns
|
|
347
|
-
|
|
405
|
+
|
|
348
406
|
config_table = Table(show_header=False, box=None, padding=(0, 1))
|
|
349
407
|
config_table.add_column("Item", style="cyan", no_wrap=True)
|
|
350
408
|
config_table.add_column("Status")
|
|
351
|
-
|
|
352
|
-
config_table.add_row("📁 Directory", status[
|
|
353
|
-
config_table.add_row(f"{'✅' if status['config_exists'] else '❌'} Config", str(status[
|
|
354
|
-
config_table.add_row(f"{'✅' if status['authorized_keys_exists'] else '❌'} Auth Keys", str(status[
|
|
355
|
-
config_table.add_row(f"{'✅' if status['known_hosts_exists'] else '❌'} Known Hosts", str(status[
|
|
409
|
+
|
|
410
|
+
config_table.add_row("📁 Directory", status["ssh_dir_path"])
|
|
411
|
+
config_table.add_row(f"{'✅' if status['config_exists'] else '❌'} Config", str(status["config_exists"]))
|
|
412
|
+
config_table.add_row(f"{'✅' if status['authorized_keys_exists'] else '❌'} Auth Keys", str(status["authorized_keys_exists"]))
|
|
413
|
+
config_table.add_row(f"{'✅' if status['known_hosts_exists'] else '❌'} Known Hosts", str(status["known_hosts_exists"]))
|
|
356
414
|
|
|
357
415
|
config_panel = Panel(config_table, title="SSH Config", border_style="yellow", padding=(1, 2), expand=False)
|
|
358
416
|
|
|
@@ -368,7 +426,7 @@ def _display_ssh_status(status: dict[str, Any]) -> None:
|
|
|
368
426
|
keys_table.add_row(key["name"], pub_status, priv_status)
|
|
369
427
|
|
|
370
428
|
keys_panel = Panel(keys_table, title=f"SSH Keys ({len(status['keys'])})", border_style="yellow", padding=(1, 2), expand=False)
|
|
371
|
-
|
|
429
|
+
|
|
372
430
|
console.print(Columns([config_panel, keys_panel], equal=False, expand=True))
|
|
373
431
|
else:
|
|
374
432
|
console.print(config_panel)
|
|
@@ -379,7 +437,9 @@ def _display_config_files_status(status: dict[str, Any]) -> None:
|
|
|
379
437
|
console.rule("[bold bright_blue]⚙️ Configuration Files[/bold bright_blue]")
|
|
380
438
|
|
|
381
439
|
if "error" in status:
|
|
382
|
-
console.print(
|
|
440
|
+
console.print(
|
|
441
|
+
Panel(f"❌ Error reading configuration: {status['error']}", title="Configuration Files", border_style="red", padding=(1, 2), expand=False)
|
|
442
|
+
)
|
|
383
443
|
return
|
|
384
444
|
|
|
385
445
|
public_percentage = (status["public_linked"] / status["public_count"] * 100) if status["public_count"] > 0 else 0
|
|
@@ -390,9 +450,9 @@ def _display_config_files_status(status: dict[str, Any]) -> None:
|
|
|
390
450
|
table.add_column("Linked", justify="right")
|
|
391
451
|
table.add_column("Total", justify="right")
|
|
392
452
|
table.add_column("Progress", justify="right")
|
|
393
|
-
|
|
394
|
-
table.add_row("📂 Public", str(status[
|
|
395
|
-
table.add_row("🔒 Private", str(status[
|
|
453
|
+
|
|
454
|
+
table.add_row("📂 Public", str(status["public_linked"]), str(status["public_count"]), f"{public_percentage:.0f}%")
|
|
455
|
+
table.add_row("🔒 Private", str(status["private_linked"]), str(status["private_count"]), f"{private_percentage:.0f}%")
|
|
396
456
|
|
|
397
457
|
overall_linked = status["public_linked"] + status["private_linked"]
|
|
398
458
|
overall_total = status["public_count"] + status["private_count"]
|
|
@@ -400,7 +460,9 @@ def _display_config_files_status(status: dict[str, Any]) -> None:
|
|
|
400
460
|
|
|
401
461
|
border_style = "green" if overall_percentage > 80 else ("yellow" if overall_percentage > 50 else "red")
|
|
402
462
|
|
|
403
|
-
console.print(
|
|
463
|
+
console.print(
|
|
464
|
+
Panel(table, title=f"Configuration Files ({overall_percentage:.0f}% configured)", border_style=border_style, padding=(1, 2), expand=False)
|
|
465
|
+
)
|
|
404
466
|
|
|
405
467
|
|
|
406
468
|
def _display_tools_status(grouped_tools: dict[str, dict[str, bool]]) -> None:
|
|
@@ -408,60 +470,61 @@ def _display_tools_status(grouped_tools: dict[str, dict[str, bool]]) -> None:
|
|
|
408
470
|
console.rule("[bold bright_magenta]🛠️ Important Tools[/bold bright_magenta]")
|
|
409
471
|
|
|
410
472
|
from rich.columns import Columns
|
|
411
|
-
|
|
473
|
+
|
|
412
474
|
all_group_panels = []
|
|
413
475
|
total_installed = 0
|
|
414
476
|
total_tools = 0
|
|
415
|
-
|
|
477
|
+
|
|
416
478
|
for group_name, tools in grouped_tools.items():
|
|
417
479
|
sorted_tools = sorted(tools.keys())
|
|
418
480
|
installed = [tool for tool, status in tools.items() if status]
|
|
419
481
|
total_installed += len(installed)
|
|
420
482
|
total_tools += len(tools)
|
|
421
|
-
|
|
483
|
+
|
|
422
484
|
num_columns = 8
|
|
423
485
|
tools_per_column = (len(sorted_tools) + num_columns - 1) // num_columns
|
|
424
|
-
|
|
486
|
+
|
|
425
487
|
tables = []
|
|
426
488
|
for col_idx in range(num_columns):
|
|
427
489
|
table = Table(show_header=False, box=None, padding=(0, 0), collapse_padding=True)
|
|
428
490
|
table.add_column("Tool", style="cyan", no_wrap=True, width=None)
|
|
429
491
|
table.add_column("", justify="center", width=2, no_wrap=True)
|
|
430
|
-
|
|
492
|
+
|
|
431
493
|
start_idx = col_idx * tools_per_column
|
|
432
494
|
end_idx = min(start_idx + tools_per_column, len(sorted_tools))
|
|
433
|
-
|
|
495
|
+
|
|
434
496
|
for i in range(start_idx, end_idx):
|
|
435
497
|
tool = sorted_tools[i]
|
|
436
498
|
status_icon = "✅" if tools[tool] else "❌"
|
|
437
499
|
table.add_row(tool, status_icon)
|
|
438
|
-
|
|
500
|
+
|
|
439
501
|
if start_idx < len(sorted_tools):
|
|
440
502
|
tables.append(table)
|
|
441
503
|
|
|
442
504
|
installed_percentage = (len(installed) / len(tools) * 100) if tools else 0
|
|
443
505
|
border_style = "green" if installed_percentage > 80 else ("yellow" if installed_percentage > 50 else "red")
|
|
444
|
-
|
|
506
|
+
|
|
445
507
|
group_display_name = group_name.replace("_", " ").title()
|
|
446
508
|
group_panel = Panel(
|
|
447
509
|
Columns(tables, equal=False, expand=False, padding=(0, 1)),
|
|
448
510
|
title=f"{group_display_name} ({len(installed)}/{len(tools)})",
|
|
449
511
|
border_style=border_style,
|
|
450
512
|
padding=(0, 1),
|
|
451
|
-
expand=False
|
|
513
|
+
expand=False,
|
|
452
514
|
)
|
|
453
515
|
all_group_panels.append(group_panel)
|
|
454
|
-
|
|
516
|
+
|
|
455
517
|
overall_percentage = (total_installed / total_tools * 100) if total_tools else 0
|
|
456
518
|
master_border_style = "green" if overall_percentage > 80 else ("yellow" if overall_percentage > 50 else "red")
|
|
457
|
-
|
|
519
|
+
|
|
458
520
|
from rich.console import Group
|
|
521
|
+
|
|
459
522
|
master_panel = Panel(
|
|
460
523
|
Group(*all_group_panels),
|
|
461
524
|
title=f"🛠️ Tools Overview ({total_installed}/{total_tools} installed - {overall_percentage:.0f}%)",
|
|
462
525
|
border_style=master_border_style,
|
|
463
526
|
padding=(1, 2),
|
|
464
|
-
expand=False
|
|
527
|
+
expand=False,
|
|
465
528
|
)
|
|
466
529
|
console.print(master_panel)
|
|
467
530
|
|
|
@@ -473,9 +536,9 @@ def _display_backup_status(status: dict[str, Any]) -> None:
|
|
|
473
536
|
table = Table(show_header=False, box=None, padding=(0, 1), expand=False)
|
|
474
537
|
table.add_column("Property", style="cyan", no_wrap=True)
|
|
475
538
|
table.add_column("Value", style="white")
|
|
476
|
-
|
|
477
|
-
table.add_row("🌥️ Cloud Config", status[
|
|
478
|
-
table.add_row("📦 Backup Items", str(status[
|
|
539
|
+
|
|
540
|
+
table.add_row("🌥️ Cloud Config", status["cloud_config"])
|
|
541
|
+
table.add_row("📦 Backup Items", str(status["backup_items_count"]))
|
|
479
542
|
|
|
480
543
|
border_style = "green" if status["cloud_config"] != "Not configured" else "yellow"
|
|
481
544
|
|
|
@@ -175,10 +175,9 @@ def visualize(
|
|
|
175
175
|
gource_cmd: str = str(gource_exe)
|
|
176
176
|
else:
|
|
177
177
|
print("❌ Installation failed, falling back to system gource")
|
|
178
|
-
|
|
178
|
+
raise typer.Exit(1)
|
|
179
179
|
else:
|
|
180
|
-
|
|
181
|
-
print(f"⚠️ Portable gource not found at {gource_exe}, using system gource")
|
|
180
|
+
raise FileNotFoundError(f"Gource executable not found at {gource_exe}. Please install gource using your package manager.")
|
|
182
181
|
else:
|
|
183
182
|
gource_cmd = str(gource_exe)
|
|
184
183
|
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Requires: fzf, oh-my-posh
|
|
2
|
+
# Purpose: Interactive Oh My Posh theme chooser with live preview
|
|
3
|
+
|
|
4
|
+
# Path to your Oh My Posh themes directory
|
|
5
|
+
$themesDir = "$env:LOCALAPPDATA\Programs\oh-my-posh\themes"
|
|
6
|
+
|
|
7
|
+
if (-not (Test-Path $themesDir)) {
|
|
8
|
+
Write-Host "Themes directory not found at $themesDir" -ForegroundColor Red
|
|
9
|
+
exit 1
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
# Get all theme files and extract just the theme names for display
|
|
13
|
+
$themes = Get-ChildItem $themesDir -Filter "*.omp.json" | ForEach-Object {
|
|
14
|
+
[PSCustomObject]@{
|
|
15
|
+
Name = $_.BaseName
|
|
16
|
+
Path = $_.FullName
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
# Create a simple preview command that shows theme name and a sample prompt
|
|
21
|
+
$previewCommand = "pwsh -NoProfile -Command `"Write-Host 'Theme: ' -NoNewline -ForegroundColor Cyan; Write-Host (Split-Path '{}' -Leaf); Write-Host ''; oh-my-posh print primary --config '{}' 2>`$null`""
|
|
22
|
+
|
|
23
|
+
# Run fzf with preview
|
|
24
|
+
$selectedThemeName = $themes | ForEach-Object { $_.Path } |
|
|
25
|
+
fzf --height 80% --border --ansi --reverse `
|
|
26
|
+
--header "Select an Oh My Posh theme (Ctrl+C to cancel)" `
|
|
27
|
+
--preview $previewCommand `
|
|
28
|
+
--preview-window=right:60%:wrap
|
|
29
|
+
|
|
30
|
+
# After fzf selection
|
|
31
|
+
if ($selectedThemeName) {
|
|
32
|
+
Write-Host "`nYou selected:" -ForegroundColor Green
|
|
33
|
+
Write-Host (Split-Path $selectedThemeName -Leaf) -ForegroundColor Yellow
|
|
34
|
+
Write-Host "`nApplying theme..." -ForegroundColor Cyan
|
|
35
|
+
|
|
36
|
+
# Apply the theme to current session
|
|
37
|
+
oh-my-posh init pwsh --config $selectedThemeName | Invoke-Expression
|
|
38
|
+
|
|
39
|
+
Write-Host "`nTheme applied to current session!" -ForegroundColor Green
|
|
40
|
+
Write-Host "To make this permanent, add this line to your PowerShell profile:" -ForegroundColor Cyan
|
|
41
|
+
Write-Host "oh-my-posh init pwsh --config '$selectedThemeName' | Invoke-Expression" -ForegroundColor Yellow
|
|
42
|
+
} else {
|
|
43
|
+
Write-Host "`nNo theme selected." -ForegroundColor DarkGray
|
|
44
|
+
}
|
|
@@ -69,7 +69,7 @@ catch {
|
|
|
69
69
|
# }
|
|
70
70
|
|
|
71
71
|
|
|
72
|
-
oh-my-posh --init --shell pwsh --config $env:USERPROFILE/AppData/Local/Programs/oh-my-posh/themes/atomicBit.omp.json | Invoke-Expression
|
|
72
|
+
# oh-my-posh --init --shell pwsh --config $env:USERPROFILE/AppData/Local/Programs/oh-my-posh/themes/atomicBit.omp.json | Invoke-Expression
|
|
73
73
|
|
|
74
74
|
# try {
|
|
75
75
|
# Invoke-Expression (&starship init powershell)
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
if (-not (Test-Path -Path "$HOME\.local\bin\uv.exe")) {
|
|
4
4
|
Write-Output "uv binary not found, installing..."
|
|
5
|
-
irm https://astral.sh/uv/install.ps1 | iex
|
|
5
|
+
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
|
|
6
6
|
} else {
|
|
7
7
|
Write-Output "uv binary found, updating..."
|
|
8
8
|
& "$HOME\.local\bin\uv.exe" self update
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
uv run --python 3.13 --with machineconfig devops self interactive
|
|
3
|
+
iex (iwr "https://raw.githubusercontent.com/thisismygitrepo/machineconfig/main/src/machineconfig/setup_windows/uv.ps1").Content
|
|
4
|
+
& "$HOME\.local\bin\uv.exe" run --python 3.13 --with machineconfig devops self interactive
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
from machineconfig.utils.path_extended import PathExtended
|
|
2
2
|
from machineconfig.utils.installer_utils.installer_abc import find_move_delete_linux, find_move_delete_windows
|
|
3
|
-
from machineconfig.utils.source_of_truth import INSTALL_TMP_DIR, INSTALL_VERSION_ROOT
|
|
3
|
+
from machineconfig.utils.source_of_truth import INSTALL_TMP_DIR, INSTALL_VERSION_ROOT
|
|
4
4
|
from machineconfig.utils.installer_utils.installer_abc import check_tool_exists
|
|
5
|
-
from machineconfig.utils.
|
|
6
|
-
from machineconfig.utils.schemas.installer.installer_types import InstallerData, InstallerDataFiles, get_os_name, get_normalized_arch
|
|
5
|
+
from machineconfig.utils.schemas.installer.installer_types import InstallerData, get_os_name, get_normalized_arch
|
|
7
6
|
|
|
8
7
|
import platform
|
|
9
8
|
import subprocess
|
|
10
9
|
import json
|
|
11
10
|
from typing import Optional, Any
|
|
12
|
-
from pathlib import Path
|
|
13
11
|
from urllib.parse import urlparse
|
|
14
12
|
|
|
15
13
|
|
|
@@ -88,7 +86,7 @@ class Installer:
|
|
|
88
86
|
if result.stderr:
|
|
89
87
|
print(f"STDERR: {result.stderr}")
|
|
90
88
|
print(f"Return code: {result.returncode}")
|
|
91
|
-
print(
|
|
89
|
+
print("✅ Package manager installation completed")
|
|
92
90
|
elif installer_arch_os.endswith((".sh", ".py", ".ps1")):
|
|
93
91
|
# search for the script, see which path ends with the script name
|
|
94
92
|
import machineconfig.jobs.installer as module
|
|
@@ -200,7 +200,7 @@ machineconfig/scripts/python/devops_helpers/__init__.py,sha256=47DEQpj8HBSa-_TIm
|
|
|
200
200
|
machineconfig/scripts/python/devops_helpers/devops_add_identity.py,sha256=wvjNgqsLmqD2SxbNCW_usqfp0LI-TDvcJJKGOWt2oFw,3775
|
|
201
201
|
machineconfig/scripts/python/devops_helpers/devops_add_ssh_key.py,sha256=BXB-9RvuSZO0YTbnM2azeABW2ngLW4SKhhAGAieMzfw,6873
|
|
202
202
|
machineconfig/scripts/python/devops_helpers/devops_backup_retrieve.py,sha256=JLJHmi8JmZ_qVTeMW-qBEAYGt1fmfWXzZ7Gm-Q-GDcU,5585
|
|
203
|
-
machineconfig/scripts/python/devops_helpers/devops_status.py,sha256=
|
|
203
|
+
machineconfig/scripts/python/devops_helpers/devops_status.py,sha256=C1akn6mGteBVV9CiQnUX6H32ehnCgMdCyNgojXVQeqA,23287
|
|
204
204
|
machineconfig/scripts/python/devops_helpers/devops_update_repos.py,sha256=OarxDD532sA0Tk4Ek2I9J_dAV0MgiV9mUG4hQZBpF6Y,9407
|
|
205
205
|
machineconfig/scripts/python/helpers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
206
206
|
machineconfig/scripts/python/helpers/cloud_helpers.py,sha256=GA-bxXouUmknk9fyQAsPT-Xl3RG9-yBed71a2tu9Pig,4914
|
|
@@ -226,7 +226,7 @@ machineconfig/scripts/python/helpers_fire_command/cloud_manager.py,sha256=YN0DYL
|
|
|
226
226
|
machineconfig/scripts/python/helpers_fire_command/fire_jobs_args_helper.py,sha256=UUrGB2N_pR7PxFKtKTJxIUiS58WjQX0U50y2ft8Ul4w,4334
|
|
227
227
|
machineconfig/scripts/python/helpers_fire_command/fire_jobs_route_helper.py,sha256=9zGuh_bMkQgfMS0nnFoa2oIWdmLAkSNtlEH4H-FprmM,5373
|
|
228
228
|
machineconfig/scripts/python/helpers_fire_command/fire_jobs_streamlit_helper.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
229
|
-
machineconfig/scripts/python/helpers_repos/grource.py,sha256=
|
|
229
|
+
machineconfig/scripts/python/helpers_repos/grource.py,sha256=IywQ1NDPcLXM5Tr9xhmq4tHfYspLRs3pF20LP2TlgIQ,14595
|
|
230
230
|
machineconfig/scripts/python/repos_helpers/count_lines.py,sha256=ZLEajCLmlFFY969BehabqGOB9_kkpATO3Lt09L7KULk,15968
|
|
231
231
|
machineconfig/scripts/python/repos_helpers/count_lines_frontend.py,sha256=jOlMCcVgE2a-NhdUtzNK1wKMf-VGldwGHR6QA1tnFa8,559
|
|
232
232
|
machineconfig/scripts/python/repos_helpers/repos_helper.py,sha256=aP-Cy0V-4fj2dDHGdI72vPkBj33neOK_GvBgMD43dKg,2853
|
|
@@ -258,6 +258,7 @@ machineconfig/scripts/windows/nano.ps1,sha256=H1PNN1x3UnOCGwijgMij-K2ZM2E20sfsLT
|
|
|
258
258
|
machineconfig/scripts/windows/pomodoro.ps1,sha256=9r61cwRy4M2_1A-NFb0fxUuUONxXBLJmLYtY3apkyQA,80
|
|
259
259
|
machineconfig/scripts/windows/reload_path.ps1,sha256=81hQY18LFApVZWFiUfgMzzPH2pJ1WD1fHInfmicBZFA,217
|
|
260
260
|
machineconfig/scripts/windows/scheduler.ps1,sha256=YfOlBxCkPfeQPeyCiNw0g3kIpdbjjf6daLEWuyHSaXY,81
|
|
261
|
+
machineconfig/scripts/windows/select_pwsh_theme.ps1,sha256=bl27f8XAeLrm6WggorGmPR5uhsNwj5ayWsxus4UrKI8,1843
|
|
261
262
|
machineconfig/scripts/windows/sessions.ps1,sha256=cQdgSS3rVWvhthsUi5lyFI05_GKiRGI-j4FB1SZNKpM,80
|
|
262
263
|
machineconfig/scripts/windows/share_cloud.cmd,sha256=exD7JCdxw2LqVjw2MKCYHbVZlEqmelXtwnATng-dhJ4,1028
|
|
263
264
|
machineconfig/scripts/windows/share_nfs.ps1,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -320,7 +321,7 @@ machineconfig/settings/lf/windows/autocall/rename.ps1,sha256=47DEQpj8HBSa-_TImW-
|
|
|
320
321
|
machineconfig/settings/linters/.flake8,sha256=1By04Qwy5saCudYKOw2bKHSNQg4N128SJudwD3SVGhQ,1958
|
|
321
322
|
machineconfig/settings/linters/.mypy.ini,sha256=BNxVtNuliJZVeFpCRRIQpSWFDQYuKqKtcVKYcZ-sApc,811
|
|
322
323
|
machineconfig/settings/linters/.pylintrc,sha256=_hYrPgtMvQc877u5NTU_HlkJMZwuDrmB6Yt3u5zg3-c,3593
|
|
323
|
-
machineconfig/settings/linters/.ruff.toml,sha256=
|
|
324
|
+
machineconfig/settings/linters/.ruff.toml,sha256=Cw9FHSyM1oPlLJDAy9Y9GiwyuBYUWI1mqSpz94ddAhc,1655
|
|
324
325
|
machineconfig/settings/lvim/linux/config.lua,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
325
326
|
machineconfig/settings/lvim/windows/config.lua,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
326
327
|
machineconfig/settings/lvim/windows/archive/config_additional.lua,sha256=zj-VDn-Av4IomJ3EqM1gf_6VsZ9ieG815O9QK1slyPI,792
|
|
@@ -343,7 +344,7 @@ machineconfig/settings/shells/ipy/profiles/default/startup/playext.py,sha256=OJ3
|
|
|
343
344
|
machineconfig/settings/shells/kitty/kitty.conf,sha256=lDdx-dUX3jbKGb3BkS2f2TOpmgGiS-CI-_-lFvhD5A4,52870
|
|
344
345
|
machineconfig/settings/shells/nushell/config.nu,sha256=ug0E0NXNlCzgStScFN6VTsAkUaOTPJZB69P-LS5L2VE,1047
|
|
345
346
|
machineconfig/settings/shells/nushell/env.nu,sha256=4VmaXb-qP6qnMD5TPzkXMLFNlB5QC4l9HEzCvXZE2GQ,315
|
|
346
|
-
machineconfig/settings/shells/pwsh/init.ps1,sha256=
|
|
347
|
+
machineconfig/settings/shells/pwsh/init.ps1,sha256=3ayfo_DyCKEY6JHVEmFtGK7BjQqNdIUCoaScWnxBXFE,2468
|
|
347
348
|
machineconfig/settings/shells/pwsh/profile.ps1,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
348
349
|
machineconfig/settings/shells/starship/starship.toml,sha256=5rQTY7ZpKnrnhgu2Y9OJKUYMz5lPLIftO1p1VRuVZwQ,1150
|
|
349
350
|
machineconfig/settings/shells/vtm/settings.xml,sha256=5TNXd-i0eUGo2w3tuhY9aOkwoJdqih8_HO_U6uL2Dts,18262
|
|
@@ -385,7 +386,7 @@ machineconfig/setup_linux/web_shortcuts/interactive.sh,sha256=NwrHKEPHW1PIkl3Yi7
|
|
|
385
386
|
machineconfig/setup_windows/__init__.py,sha256=wVpUqoLqXl-_-bRd7gZw_PJ7WZ2GtOqfFMzo_lIwieg,454
|
|
386
387
|
machineconfig/setup_windows/apps.ps1,sha256=G5GqZ9G0aiQr_A-HaahtRdzpaTTdW6n3DRKMZWDTSPc,11214
|
|
387
388
|
machineconfig/setup_windows/machineconfig.ps1,sha256=gIQBOLIh65oUXgSjYMeYeD6lU1Bu80LZ59xqRc3T3BA,918
|
|
388
|
-
machineconfig/setup_windows/uv.ps1,sha256=
|
|
389
|
+
machineconfig/setup_windows/uv.ps1,sha256=mzkFJUQ57dukVQtY7WqAQIVUDMcixnkir8aNM_TYrl4,350
|
|
389
390
|
machineconfig/setup_windows/others/docker.ps1,sha256=M8NfsSxH8YlmY92J4rSe1xWOwTW8IFrdgb8cI8Riu2E,311
|
|
390
391
|
machineconfig/setup_windows/others/obs.ps1,sha256=2andchcXpxS3rqZjGaMpY5VShxTAKWvw6eCrayjuaLo,30
|
|
391
392
|
machineconfig/setup_windows/others/power_options.ps1,sha256=c7Hn94jBD5GWF29CxMhmNpuM0hgXTQgVJmIRR_7sdcY,182
|
|
@@ -393,7 +394,7 @@ machineconfig/setup_windows/ssh/openssh-server.ps1,sha256=7FopRdNn8hQbst4Cq_T1qo
|
|
|
393
394
|
machineconfig/setup_windows/ssh/openssh-server_add-sshkey.ps1,sha256=qiNC02kzUZi6KBV7O-nRQ7pQ0OGixbq-rUvSCQ7TVxc,1656
|
|
394
395
|
machineconfig/setup_windows/ssh/openssh-server_add_identity.ps1,sha256=b8ZXpmNUSw3IMYvqSY7ClpdWPG39FS7MefoWnRhWN2U,506
|
|
395
396
|
machineconfig/setup_windows/ssh/openssh_all.ps1,sha256=-mBGNRJSxsY6Z3gFMwIoL_3poj943acjfzXwGo2YFu4,864
|
|
396
|
-
machineconfig/setup_windows/web_shortcuts/interactive.ps1,sha256=
|
|
397
|
+
machineconfig/setup_windows/web_shortcuts/interactive.ps1,sha256=47KY5sr8Cy3bfzFCszwnGeQpIHpjh7r8_znv3TZhqWY,221
|
|
397
398
|
machineconfig/setup_windows/wt_and_pwsh/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
398
399
|
machineconfig/setup_windows/wt_and_pwsh/set_wt_settings.py,sha256=ogxJnwpdcpH7N6dFJu95UCNoGYirZKQho_3X0F_hmXs,6791
|
|
399
400
|
machineconfig/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -428,13 +429,13 @@ machineconfig/utils/installer_utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQ
|
|
|
428
429
|
machineconfig/utils/installer_utils/github_release_bulk.py,sha256=WJf_qZlF02SmIc6C7o1h4Gy4gAaJAfeAS8O9s2Itj-k,6535
|
|
429
430
|
machineconfig/utils/installer_utils/installer.py,sha256=CfBwtES-T0hhF-IHfbpyPn_tUz0YaVEk9sMV96oc0-w,9313
|
|
430
431
|
machineconfig/utils/installer_utils/installer_abc.py,sha256=IxAN2QDohMAudNY_snW88NPU2S8ZUp8_2BPC32R4d_s,11050
|
|
431
|
-
machineconfig/utils/installer_utils/installer_class.py,sha256=
|
|
432
|
+
machineconfig/utils/installer_utils/installer_class.py,sha256=kvxsc8Ff6boqx1Llsupkp92LIsslUg5nktLLHdzZazo,18219
|
|
432
433
|
machineconfig/utils/schemas/fire_agents/fire_agents_input.py,sha256=Xbi59rU35AzR7HZZ8ZQ8aUu_FjSgijNqc8Sme0rCk2Y,2050
|
|
433
434
|
machineconfig/utils/schemas/installer/installer_types.py,sha256=QClRY61QaduBPJoSpdmTIdgS9LS-RvE-QZ-D260tD3o,1214
|
|
434
435
|
machineconfig/utils/schemas/layouts/layout_types.py,sha256=TcqlZdGVoH8htG5fHn1KWXhRdPueAcoyApppZsPAPto,2020
|
|
435
436
|
machineconfig/utils/schemas/repos/repos_types.py,sha256=ECVr-3IVIo8yjmYmVXX2mnDDN1SLSwvQIhx4KDDQHBQ,405
|
|
436
|
-
machineconfig-5.
|
|
437
|
-
machineconfig-5.
|
|
438
|
-
machineconfig-5.
|
|
439
|
-
machineconfig-5.
|
|
440
|
-
machineconfig-5.
|
|
437
|
+
machineconfig-5.30.dist-info/METADATA,sha256=-j5Ky-WUo8hIK9xATBPhQxUkKz3wyju78hGUo1UJ46k,2495
|
|
438
|
+
machineconfig-5.30.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
439
|
+
machineconfig-5.30.dist-info/entry_points.txt,sha256=8jXeXoGGihOkQtKV0VYlm6lq5ewDh2eXR_LcccRkbws,999
|
|
440
|
+
machineconfig-5.30.dist-info/top_level.txt,sha256=porRtB8qms8fOIUJgK-tO83_FeH6Bpe12oUVC670teA,14
|
|
441
|
+
machineconfig-5.30.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|