machineconfig 2.3__py3-none-any.whl → 2.5__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.

Files changed (86) hide show
  1. machineconfig/__init__.py +30 -0
  2. machineconfig/jobs/__pycache__/__init__.cpython-313.pyc +0 -0
  3. machineconfig/jobs/python_custom_installers/__pycache__/__init__.cpython-313.pyc +0 -0
  4. machineconfig/jobs/python_generic_installers/__pycache__/__init__.cpython-313.pyc +0 -0
  5. machineconfig/jobs/python_linux_installers/__pycache__/__init__.cpython-313.pyc +0 -0
  6. machineconfig/scripts/__pycache__/__init__.cpython-313.pyc +0 -0
  7. machineconfig/scripts/linux/checkout_versions +1 -7
  8. machineconfig/scripts/linux/choose_wezterm_theme +1 -7
  9. machineconfig/scripts/linux/cloud_copy +1 -8
  10. machineconfig/scripts/linux/cloud_manager +1 -7
  11. machineconfig/scripts/linux/cloud_mount +1 -23
  12. machineconfig/scripts/linux/cloud_repo_sync +1 -21
  13. machineconfig/scripts/linux/cloud_sync +1 -23
  14. machineconfig/scripts/linux/croshell +1 -23
  15. machineconfig/scripts/linux/devops +1 -23
  16. machineconfig/scripts/linux/fire +1 -27
  17. machineconfig/scripts/linux/fire_agents +1 -26
  18. machineconfig/scripts/linux/ftpx +1 -7
  19. machineconfig/scripts/linux/gh_models +1 -10
  20. machineconfig/scripts/linux/kill_process +1 -9
  21. machineconfig/scripts/linux/mcinit +1 -26
  22. machineconfig/scripts/linux/mount_nfs +1 -13
  23. machineconfig/scripts/linux/repos +1 -23
  24. machineconfig/scripts/linux/scheduler +1 -7
  25. machineconfig/scripts/linux/start_slidev +1 -22
  26. machineconfig/scripts/linux/start_terminals +1 -10
  27. machineconfig/scripts/linux/url2md +1 -9
  28. machineconfig/scripts/linux/wifi_conn +1 -23
  29. machineconfig/scripts/python/__pycache__/__init__.cpython-313.pyc +0 -0
  30. machineconfig/scripts/python/__pycache__/croshell.cpython-313.pyc +0 -0
  31. machineconfig/scripts/python/__pycache__/devops.cpython-313.pyc +0 -0
  32. machineconfig/scripts/python/__pycache__/devops_devapps_install.cpython-313.pyc +0 -0
  33. machineconfig/scripts/python/__pycache__/devops_update_repos.cpython-313.pyc +0 -0
  34. machineconfig/scripts/python/cloud_mount.py +4 -2
  35. machineconfig/scripts/python/cloud_repo_sync.py +5 -2
  36. machineconfig/scripts/python/cloud_sync.py +4 -2
  37. machineconfig/scripts/python/croshell.py +5 -3
  38. machineconfig/scripts/python/devops.py +2 -2
  39. machineconfig/scripts/python/fire_jobs.py +10 -8
  40. machineconfig/scripts/python/mount_nfs.py +12 -8
  41. machineconfig/scripts/python/mount_nw_drive.py +6 -6
  42. machineconfig/scripts/python/mount_ssh.py +4 -2
  43. machineconfig/scripts/python/start_slidev.py +4 -2
  44. machineconfig/scripts/python/start_terminals.py +4 -2
  45. machineconfig/scripts/windows/checkout_version.ps1 +1 -4
  46. machineconfig/scripts/windows/choose_wezterm_theme.ps1 +1 -18
  47. machineconfig/scripts/windows/cloud_copy.ps1 +1 -13
  48. machineconfig/scripts/windows/cloud_manager.ps1 +1 -8
  49. machineconfig/scripts/windows/cloud_mount.ps1 +1 -25
  50. machineconfig/scripts/windows/cloud_repo_sync.ps1 +1 -7
  51. machineconfig/scripts/windows/cloud_sync.ps1 +1 -21
  52. machineconfig/scripts/windows/croshell.ps1 +1 -40
  53. machineconfig/scripts/windows/dotfile.ps1 +1 -7
  54. machineconfig/scripts/windows/ftpx.ps1 +1 -5
  55. machineconfig/scripts/windows/kill_process.ps1 +1 -7
  56. machineconfig/scripts/windows/mcinit.ps1 +1 -4
  57. machineconfig/scripts/windows/mount_ssh.ps1 +1 -5
  58. machineconfig/scripts/windows/pomodoro.ps1 +1 -8
  59. machineconfig/scripts/windows/repos.ps1 +1 -27
  60. machineconfig/scripts/windows/scheduler.ps1 +1 -6
  61. machineconfig/scripts/windows/snapshot.ps1 +1 -5
  62. machineconfig/scripts/windows/start_slidev.ps1 +1 -21
  63. machineconfig/scripts/windows/start_terminals.ps1 +1 -22
  64. machineconfig/scripts/windows/wifi_conn.ps1 +1 -5
  65. machineconfig/scripts/windows/wsl_windows_transfer.ps1 +1 -5
  66. machineconfig/settings/__pycache__/__init__.cpython-313.pyc +0 -0
  67. machineconfig/settings/shells/ipy/profiles/default/__pycache__/__init__.cpython-313.pyc +0 -0
  68. machineconfig/settings/shells/ipy/profiles/default/startup/__pycache__/__init__.cpython-313.pyc +0 -0
  69. machineconfig/utils/code.py +5 -5
  70. machineconfig/utils/source_of_truth.py +2 -2
  71. {machineconfig-2.3.dist-info → machineconfig-2.5.dist-info}/METADATA +1 -1
  72. {machineconfig-2.3.dist-info → machineconfig-2.5.dist-info}/RECORD +75 -72
  73. machineconfig-2.5.dist-info/entry_points.txt +20 -0
  74. machineconfig/scripts/linux/archive/tmate_conn +0 -12
  75. machineconfig/scripts/linux/archive/tmate_start +0 -12
  76. machineconfig/scripts/linux/archive/transfer_wsl_win +0 -5
  77. machineconfig/scripts/windows/archive/gource2vid.ps1 +0 -14
  78. machineconfig/scripts/windows/archive/im2text.ps1 +0 -27
  79. machineconfig/scripts/windows/archive/secure_pull.ps1 +0 -46
  80. machineconfig/scripts/windows/archive/secure_push.ps1 +0 -85
  81. machineconfig/scripts/windows/archive/tmate_conn.ps1 +0 -7
  82. machineconfig/scripts/windows/py2exe.ps1 +0 -10
  83. machineconfig/scripts/windows/utils/op_script_delete.ps1 +0 -7
  84. machineconfig-2.3.dist-info/entry_points.txt +0 -2
  85. {machineconfig-2.3.dist-info → machineconfig-2.5.dist-info}/WHEEL +0 -0
  86. {machineconfig-2.3.dist-info → machineconfig-2.5.dist-info}/top_level.txt +0 -0
@@ -4,7 +4,7 @@ from machineconfig.utils.path_reduced import PathExtended as PathExtended
4
4
  from machineconfig.utils.ssh import SSH
5
5
  from machineconfig.utils.terminal import Terminal
6
6
  from machineconfig.utils.options import display_options, choose_ssh_host
7
- from machineconfig.utils.source_of_truth import PROGRAM_PATH
7
+
8
8
  import platform
9
9
 
10
10
 
@@ -42,12 +42,15 @@ def main():
42
42
  assert isinstance(local_mount_point, PathExtended), f"❌ local_mount_point must be a pathlib.Path. Got {type(local_mount_point)}"
43
43
  local_mount_point = PathExtended(local_mount_point).expanduser()
44
44
 
45
- PROGRAM_PATH.write_text(f"""
45
+ txt = f"""
46
46
  share_info={share_info}
47
47
  remote_server={remote_server}
48
48
  share_path={share_path}
49
49
  local_mount_point={local_mount_point}
50
- """)
50
+ """
51
+ # PROGRAM_PATH.write_text(txt)
52
+ import subprocess
53
+ subprocess.run(txt, shell=True, check=True)
51
54
 
52
55
  print("✅ Mount paths prepared successfully!\n")
53
56
 
@@ -55,18 +58,19 @@ local_mount_point={local_mount_point}
55
58
  print("\n🔍 Checking existing drives...")
56
59
  print(Terminal().run("Get-PSDrive -PSProvider 'FileSystem'", shell="powershell").op)
57
60
  driver_letter = input(r"🖥️ Choose driver letter (e.g., Z:\\) [Avoid already used ones]: ") or "Z:\\"
58
-
59
- PROGRAM_PATH.write_text(f"""
61
+ txt = f"""
60
62
  $server = "{remote_server}"
61
63
  $sharePath = "{share_path}"
62
64
  $driveLetter = "{driver_letter}"
63
- """)
64
-
65
+ """
66
+ # PROGRAM_PATH.write_text(txt)
67
+ import subprocess
68
+ subprocess.run(txt, shell=True, check=True)
65
69
  print("✅ Drive letter selected and configuration saved!\n")
66
70
 
67
71
  print("\n📄 Configuration File Content:")
68
72
  print("-" * 50)
69
- print(PROGRAM_PATH.read_text(encoding="utf-8"))
73
+ # print(PROGRAM_PATH.read_text(encoding="utf-8"))
70
74
  print("-" * 50 + "\n")
71
75
 
72
76
  print("🎉 NFS Mounting Process Completed Successfully!\n")
@@ -1,4 +1,4 @@
1
- from machineconfig.utils.source_of_truth import PROGRAM_PATH
1
+
2
2
  from pathlib import Path
3
3
  import platform
4
4
 
@@ -25,16 +25,16 @@ def main():
25
25
 
26
26
  if platform.system() in ["Linux", "Darwin"]:
27
27
  print("\n🔧 Saving configuration for Linux...")
28
- PROGRAM_PATH.write_text(
29
- f"""
28
+ txt = f"""
30
29
  drive_location='{drive_location}'
31
30
  mount_point='{mount_point}'
32
31
  username='{username}'
33
32
  password='{password}'
34
33
 
35
- """,
36
- encoding="utf-8",
37
- )
34
+ """
35
+ # PROGRAM_PATH.write_text(txt, encoding="utf-8",)
36
+ import subprocess
37
+ subprocess.run(txt, shell=True, check=True)
38
38
  print("✅ Configuration saved successfully!\n")
39
39
 
40
40
  elif platform.system() == "Windows":
@@ -4,7 +4,7 @@ from platform import system
4
4
  from machineconfig.utils.ssh import SSH
5
5
  from machineconfig.utils.terminal import Terminal
6
6
  from machineconfig.utils.path_reduced import PathExtended as PathExtended
7
- from machineconfig.utils.source_of_truth import PROGRAM_PATH
7
+
8
8
  from machineconfig.utils.options import choose_ssh_host
9
9
 
10
10
 
@@ -52,7 +52,9 @@ fusermount -u /mnt/dbhdd
52
52
  else:
53
53
  raise ValueError(f"❌ Not implemented for this system: {system()}")
54
54
 
55
- PROGRAM_PATH.write_text(txt, encoding="utf-8")
55
+ # PROGRAM_PATH.write_text(txt, encoding="utf-8")
56
+ import subprocess
57
+ subprocess.run(txt, shell=True, check=True)
56
58
  print("✅ Configuration saved successfully!\n")
57
59
 
58
60
  print("🎉 SSHFS Mounting Process Completed!\n")
@@ -2,7 +2,7 @@
2
2
  slidev
3
3
  """
4
4
 
5
- from machineconfig.utils.source_of_truth import CONFIG_PATH, PROGRAM_PATH
5
+ from machineconfig.utils.source_of_truth import CONFIG_PATH
6
6
  from machineconfig.utils.code import print_code
7
7
  from machineconfig.utils.path_reduced import PathExtended as PathExtended
8
8
  from machineconfig.utils.terminal import Terminal
@@ -101,7 +101,9 @@ def main() -> None:
101
101
  print(f" - http://{local_ip_v4}:{port}\n")
102
102
 
103
103
  program = "npm run dev slides.md -- --remote"
104
- PROGRAM_PATH.write_text(program, encoding="utf-8")
104
+ # PROGRAM_PATH.write_text(program, encoding="utf-8")
105
+ import subprocess
106
+ subprocess.run(program, shell=True, cwd=SLIDEV_REPO)
105
107
  print_code(code=program, lexer="bash", desc="Run the following command to start the presentation")
106
108
 
107
109
 
@@ -1,6 +1,6 @@
1
1
  """Script to start terminals on windows and wsl"""
2
2
 
3
- from machineconfig.utils.source_of_truth import PROGRAM_PATH
3
+
4
4
  from machineconfig.utils.options import display_options, get_ssh_hosts
5
5
  import platform
6
6
  from itertools import cycle
@@ -111,7 +111,9 @@ def main():
111
111
  print(cmd)
112
112
  print("-" * 50 + "\n")
113
113
 
114
- PROGRAM_PATH.write_text(cmd, encoding="utf-8")
114
+ # PROGRAM_PATH.write_text(cmd, encoding="utf-8")
115
+ import subprocess
116
+ subprocess.run(cmd, shell=True)
115
117
  print("✅ Command saved successfully!\n")
116
118
 
117
119
 
@@ -1,4 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
- python -m fire machineconfig.jobs.python.checkout_version main
4
- deactivate
1
+ uv run --python 3.13 --with machineconfig python -m fire machineconfig.jobs.python.checkout_version main
@@ -1,18 +1 @@
1
-
2
- $tmp = Get-Location
3
-
4
- if ($args[0] -eq $null) {
5
- $name = ""
6
- }
7
- else {
8
- $name = $args[0]
9
- }
10
-
11
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
12
-
13
- python -m fire machineconfig.scripts.python.choose_wezterm_theme main2 $args[0]
14
- .$profile # reload the profile
15
-
16
- cd $tmp
17
- deactivate -ErrorAction SilentlyContinue
18
-
1
+ uv run --python 3.13 --with machineconfig python -m fire machineconfig.scripts.python.choose_wezterm_theme main2 $args[0]
@@ -1,13 +1 @@
1
-
2
- #~/code/machineconfig/.venv/Scripts/Activate.ps1
3
- # . $PSScriptRoot/activate_ve.ps1
4
- # python -m machineconfig.scripts.python.cloud_copy $args
5
- # deactivate -ErrorAction SilentlyContinue
6
- try {
7
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
8
- python -m machineconfig.scripts.python.cloud_copy $args
9
- } catch {
10
- Write-Error $_.Exception.Message
11
- } finally {
12
- deactivate -ErrorAction SilentlyContinue
13
- }
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.cloud_copy $args
@@ -1,8 +1 @@
1
-
2
- # . $PSScriptRoot/activate_ve.ps1 ve # use the default ve.
3
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
4
-
5
- # python -i $PSScriptRoot/../python/cloud_manager.py $args
6
- python -i -m machineconfig.scripts.python.cloud_manager $args
7
-
8
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -i -m machineconfig.scripts.python.cloud_manager $args
@@ -1,25 +1 @@
1
-
2
-
3
- # ensure that python-output-script is deleted.
4
- $op_script = "~/tmp_results/shells/python_return_command.ps1"
5
- if (Test-Path $op_script ) {
6
- Remove-Item $op_script
7
- }
8
-
9
- . $PSScriptRoot/activate_ve.ps1 ve
10
- $script_root = (Get-Item $PSScriptRoot).Target # resolves symlink if any
11
- if ( $script_root -eq $null) { # this does happen if a virtual enviroment is activated before running this script (don't know why)
12
- $script_root = $PSScriptRoot
13
- }
14
-
15
- # python -m fire $script_root/../python/cloud_mount.py $args
16
- python -m machineconfig.scripts.python.cloud_mount $args
17
- if (Test-Path $op_script ) {
18
- . $op_script
19
- }
20
- else
21
- {
22
- Write-Host "No output script to be executed @ $op_script"
23
- }
24
-
25
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.cloud_mount $args
@@ -1,7 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
-
4
- # python $PSScriptRoot/../python/cloud_repo_sync.py $args
5
- python -m machineconfig.scripts.python.cloud_repo_sync $args
6
-
7
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.cloud_repo_sync $args
@@ -1,21 +1 @@
1
-
2
- # ensure that python-output-script is deleted.
3
- $op_script = "$HOME/tmp_results/shells/python_return_command.ps1"
4
- if (Test-Path $op_script ) {
5
- Remove-Item $op_script
6
- }
7
-
8
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
9
-
10
- # python $PSScriptRoot/../python/cloud_sync.py $args
11
- python -m machineconfig.scripts.python.cloud_sync $args
12
-
13
- if (Test-Path $op_script ) {
14
- . $op_script
15
- }
16
- else
17
- {
18
- Write-Host "No output script to be executed @ $op_script"
19
- }
20
-
21
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.cloud_sync $args
@@ -1,40 +1 @@
1
-
2
- $op_script = "~/tmp_results/shells/python_return_command.ps1"
3
- if (Test-Path $op_script ) {
4
- Remove-Item $op_script
5
- }
6
-
7
- $ErrorActionPreference = "Stop"
8
- #~/code/machineconfig/.venv/Scripts/Activate.ps1 # fixed ve
9
-
10
- # Locate the python script to run relative to the current directory (which might be a symlink)
11
- # $script_root = (Get-Item $PSScriptRoot).Target # resolves symlink if any
12
- # if ( $script_root -eq $null) { # this does happen if a virtual enviroment is activated before running this script (don't know why)
13
- # $script_root = $PSScriptRoot
14
- # }
15
- # if ( $script_root -eq $null) {
16
- # # echo $MyInvocation.MyCommand.Path
17
- # $script_root = Split-Path -Path $MyInvocation.MyCommand.Path -Parent
18
- # }
19
-
20
- $script_root = $MyInvocation.MyCommand.Path
21
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
22
-
23
- #. "$script_root\..\activate_ve.ps1" # dynamic v
24
-
25
- python -m machineconfig.scripts.python.croshell $args
26
- # python -m machineconfig.scripts.python.fire_jobs $args
27
-
28
-
29
- if (Test-Path $op_script ) {
30
- . $op_script
31
- # content of $op_script
32
- # $content = Get-Content $op_script
33
- # Invoke-Expression $content | Add-History # this way, $content will go to hisyory of powershell. You don't neet Add-history
34
- }
35
- else
36
- {
37
- Write-Host "No output script to be executed @ $op_script"
38
- }
39
-
40
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.croshell $args
@@ -1,7 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
-
4
- # python $PSScriptRoot/../python/dotfile.py $args
5
- python -m machineconfig.scripts.python.dotfile $args
6
-
7
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.dotfile $args
@@ -1,5 +1 @@
1
-
2
- #~/code/machineconfig/.venv/Scripts/Activate.ps1
3
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
4
- python $PSScriptRoot/../python/ftpx.py $args
5
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python $PSScriptRoot/../python/ftpx.py $args
@@ -1,7 +1 @@
1
-
2
-
3
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
4
-
5
- python -c "from machineconfig.utils.procs import ProcessManager; ProcessManager().choose_and_kill()"
6
- deactivate
7
-
1
+ uv run --python 3.13 --with machineconfig python -c "from machineconfig.utils.procs import ProcessManager; ProcessManager().choose_and_kill()"
@@ -1,4 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
- python -m machineconfig.scripts.python.ai.mcinit $args
4
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.ai.mcinit $args
@@ -7,11 +7,7 @@ $user = ''
7
7
  $sharePath = ''
8
8
  $driveLetter = ''
9
9
 
10
- # . activate_ve
11
- . $HOME/code/machineconfig/.venv/Scripts/activate.ps1
12
-
13
- python -m machineconfig.scripts.python.mount_ssh
14
- . $HOME/tmp_results/shells/python_return_command.ps1
10
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.mount_ssh
15
11
 
16
12
  net use T: \\sshfs.kr\$user@$host.local
17
13
  # this worked: net use T: \\sshfs\alex@alex-p51s-5.local
@@ -1,8 +1 @@
1
-
2
- # . $PSScriptRoot/activate_ve.ps1
3
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
4
-
5
- # python -m fire $PSScriptRoot/../python/pomodoro.py pomodoro $args
6
- python -m fire machineconfig.scripts.python.pomodoro pomodoro $args
7
-
8
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig -m fire machineconfig.scripts.python.pomodoro pomodoro $args
@@ -1,27 +1 @@
1
-
2
- # ensure that python-output-script is deleted.
3
- $op_script = "~/tmp_results/shells/python_return_command.ps1"
4
- if (Test-Path $op_script ) {
5
- Remove-Item $op_script
6
- }
7
-
8
- # . $PSScriptRoot/activate_ve.ps1 ve
9
-
10
- # # Locate the python script to run relative to the current directory (which might be a symlink)
11
- # $script_root = (Get-Item $PSScriptRoot).Target # resolves symlink if any
12
- # if ( $script_root -eq $null) { # this does happen if a virtual enviroment is activated before running this script (don't know why)
13
- # $script_root = $PSScriptRoot
14
- # }
15
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
16
-
17
- # python $script_root/../python/repos.py $args
18
- python -m machineconfig.scripts.python.repos $args
19
-
20
- if (Test-Path $op_script ) {
21
- . $op_script
22
- }
23
- else {
24
- Write-Host "ERROR: python script did not create shell script"
25
- }
26
-
27
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.repos $args
@@ -1,6 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
-
4
- python -m machineconfig.scripts.python.scheduler $Args
5
-
6
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.scheduler $Args
@@ -1,5 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
-
4
- python $PSScriptRoot/../python/snapshot.py $args
5
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python $PSScriptRoot/../python/snapshot.py $args
@@ -1,21 +1 @@
1
-
2
- # ensure that python-output-script is deleted.
3
- $op_script = "~/tmp_results/shells/python_return_command.ps1"
4
- if (Test-Path $op_script ) {
5
- Remove-Item $op_script
6
- }
7
-
8
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
9
-
10
- python -m machineconfig.scripts.python.start_slidev $args
11
-
12
- if (Test-Path $op_script ) {
13
- . $op_script
14
- }
15
- else
16
- {
17
- Write-Host "🤷‍♂️ No output script to be executed @ $op_script"
18
- }
19
-
20
-
21
- deactivate -ErrorAction SilentlyContinue
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.start_slidev $args
@@ -1,22 +1 @@
1
-
2
-
3
- $op_script = "~/tmp_results/shells/python_return_command.ps1"
4
- if (Test-Path $op_script ) {
5
- Remove-Item $op_script
6
- }
7
-
8
-
9
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
10
- python -m machineconfig.scripts.python.start_terminals $args
11
-
12
-
13
- if (Test-Path $op_script ) {
14
- . $op_script
15
- }
16
- else
17
- {
18
- Write-Host "No output script to be executed @ $op_script"
19
- }
20
-
21
- deactivate -ErrorAction SilentlyContinue
22
-
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.start_terminals $args
@@ -1,7 +1,3 @@
1
1
 
2
2
  $pyparser=Resolve-Path("$PSScriptRoot/../python/wifi_conn.py")
3
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
4
- echo "Running $pyparser"
5
- python $pyparser $args
6
- deactivate -ErrorAction SilentlyContinue
7
-
3
+ uv run --python 3.13 --with machineconfig python $pyparser $args
@@ -1,5 +1 @@
1
-
2
- . "$HOME\code\machineconfig\.venv\Scripts\activate.ps1"
3
- python -m machineconfig.scripts.python.wsl_windows_transfer $args
4
- deactivate -ErrorAction SilentlyContinue
5
-
1
+ uv run --python 3.13 --with machineconfig python -m machineconfig.scripts.python.wsl_windows_transfer $args
@@ -8,7 +8,7 @@ from rich.syntax import Syntax
8
8
  from machineconfig.utils.utils2 import randstr
9
9
  from machineconfig.utils.ve import get_ve_activate_line
10
10
  from machineconfig.utils.path_reduced import PathExtended as PathExtended
11
- from machineconfig.utils.source_of_truth import PROGRAM_PATH
11
+
12
12
 
13
13
 
14
14
  def get_shell_script_executing_python_file(python_file: str, func: Optional[str], ve_path: str, strict_execution: bool = True):
@@ -84,11 +84,11 @@ def write_shell_script_to_default_program_path(program: str, desc: str, preserve
84
84
  else:
85
85
  program = 'orig_path=$(cd -- "." && pwd)\n' + program + '\ncd "$orig_path" || exit'
86
86
  if display:
87
- print_code(code=program, lexer="shell", desc=desc, subtitle=str(PROGRAM_PATH))
88
- PROGRAM_PATH.parent.mkdir(parents=True, exist_ok=True)
89
- PROGRAM_PATH.write_text(program, encoding="utf-8")
87
+ print_code(code=program, lexer="shell", desc=desc, subtitle="PROGRAM")
88
+ # PROGRAM_PATH.parent.mkdir(parents=True, exist_ok=True)
89
+ # PROGRAM_PATH.write_text(program, encoding="utf-8")
90
90
  if execute:
91
- result = subprocess.run(f". {PROGRAM_PATH}", shell=True, capture_output=True, text=True)
91
+ result = subprocess.run(program, shell=True, capture_output=True, text=True)
92
92
  success = result.returncode == 0 and result.stderr == ""
93
93
  if not success:
94
94
  print("❌ 🛠️ EXECUTION | Shell script running failed")
@@ -3,12 +3,12 @@ Utils
3
3
  """
4
4
 
5
5
  import machineconfig
6
- import platform
6
+ # import platform
7
7
  from pathlib import Path
8
8
 
9
9
  LIBRARY_ROOT = Path(machineconfig.__file__).resolve().parent
10
10
  REPO_ROOT = LIBRARY_ROOT.parent.parent
11
- PROGRAM_PATH = Path(Path.home().joinpath("tmp_results", "shells", "python_return_command").__str__() + (".ps1" if platform.system() == "Windows" else ".sh"))
11
+ # PROGRAM_PATH = Path(Path.home().joinpath("tmp_results", "shells", "python_return_command").__str__() + (".ps1" if platform.system() == "Windows" else ".sh"))
12
12
  CONFIG_PATH = Path.home().joinpath(".config/machineconfig")
13
13
  DEFAULTS_PATH = Path.home().joinpath("dotfiles/machineconfig/defaults.ini")
14
14
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: machineconfig
3
- Version: 2.3
3
+ Version: 2.5
4
4
  Summary: Dotfiles management package
5
5
  Author-email: Alex Al-Saffar <programmer@usa.com>
6
6
  License: Apache 2.0