machineconfig 2.6__py3-none-any.whl → 2.7__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 (118) hide show
  1. machineconfig/cluster/remote/remote_machine.py +0 -1
  2. machineconfig/cluster/sessions_managers/wt_local.py +1 -1
  3. machineconfig/cluster/sessions_managers/wt_local_manager.py +1 -1
  4. machineconfig/cluster/sessions_managers/wt_remote.py +1 -1
  5. machineconfig/cluster/sessions_managers/wt_remote_manager.py +1 -1
  6. machineconfig/cluster/sessions_managers/wt_utils/layout_generator.py +1 -1
  7. machineconfig/cluster/sessions_managers/wt_utils/process_monitor.py +1 -1
  8. machineconfig/cluster/sessions_managers/wt_utils/status_reporter.py +1 -1
  9. machineconfig/cluster/sessions_managers/zellij_local.py +1 -1
  10. machineconfig/cluster/sessions_managers/zellij_local_manager.py +1 -1
  11. machineconfig/cluster/sessions_managers/zellij_remote.py +1 -1
  12. machineconfig/cluster/sessions_managers/zellij_remote_manager.py +1 -1
  13. machineconfig/cluster/sessions_managers/zellij_utils/example_usage.py +1 -1
  14. machineconfig/cluster/sessions_managers/zellij_utils/layout_generator.py +1 -1
  15. machineconfig/cluster/sessions_managers/zellij_utils/process_monitor.py +1 -1
  16. machineconfig/cluster/sessions_managers/zellij_utils/status_reporter.py +1 -1
  17. machineconfig/jobs/__pycache__/__init__.cpython-313.pyc +0 -0
  18. machineconfig/jobs/python/vscode/sync_code.py +0 -1
  19. machineconfig/jobs/python_generic_installers/__pycache__/__init__.cpython-313.pyc +0 -0
  20. machineconfig/jobs/python_linux_installers/__pycache__/__init__.cpython-313.pyc +0 -0
  21. machineconfig/profile/create.py +8 -16
  22. machineconfig/profile/shell.py +140 -179
  23. machineconfig/scripts/__pycache__/__init__.cpython-313.pyc +0 -0
  24. machineconfig/scripts/linux/choose_wezterm_theme +1 -1
  25. machineconfig/scripts/linux/cloud_copy +1 -1
  26. machineconfig/scripts/linux/cloud_mount +1 -1
  27. machineconfig/scripts/linux/cloud_repo_sync +1 -1
  28. machineconfig/scripts/linux/cloud_sync +1 -1
  29. machineconfig/scripts/linux/croshell +2 -1
  30. machineconfig/scripts/linux/devops +1 -1
  31. machineconfig/scripts/linux/fire +1 -1
  32. machineconfig/scripts/linux/fire_agents +1 -1
  33. machineconfig/scripts/linux/ftpx +1 -1
  34. machineconfig/scripts/linux/gh_models +1 -1
  35. machineconfig/scripts/linux/kill_process +1 -1
  36. machineconfig/scripts/linux/mcinit +1 -1
  37. machineconfig/scripts/linux/mount_nfs +1 -1
  38. machineconfig/scripts/linux/mount_nw_drive +1 -11
  39. machineconfig/scripts/linux/repos +1 -1
  40. machineconfig/scripts/linux/scheduler +1 -1
  41. machineconfig/scripts/linux/start_slidev +1 -1
  42. machineconfig/scripts/linux/start_terminals +1 -1
  43. machineconfig/scripts/linux/wifi_conn +1 -1
  44. machineconfig/scripts/python/__pycache__/__init__.cpython-313.pyc +0 -0
  45. machineconfig/scripts/python/__pycache__/cloud_repo_sync.cpython-313.pyc +0 -0
  46. machineconfig/scripts/python/__pycache__/devops.cpython-313.pyc +0 -0
  47. machineconfig/scripts/python/__pycache__/devops_devapps_install.cpython-313.pyc +0 -0
  48. machineconfig/scripts/python/__pycache__/devops_update_repos.cpython-313.pyc +0 -0
  49. machineconfig/scripts/python/__pycache__/get_zellij_cmd.cpython-313.pyc +0 -0
  50. machineconfig/scripts/python/__pycache__/repos.cpython-313.pyc +0 -0
  51. machineconfig/scripts/python/__pycache__/repos_helper_record.cpython-313.pyc +0 -0
  52. machineconfig/scripts/python/ai/mcinit.py +16 -2
  53. machineconfig/scripts/python/ai/scripts/lint_and_type_check.sh +1 -1
  54. machineconfig/scripts/python/croshell.py +0 -1
  55. machineconfig/scripts/python/devops.py +1 -13
  56. machineconfig/scripts/python/devops_update_repos.py +39 -19
  57. machineconfig/scripts/python/fire_agents.py +1 -1
  58. machineconfig/scripts/python/fire_jobs.py +8 -3
  59. machineconfig/scripts/python/fire_jobs_layout_helper.py +1 -1
  60. machineconfig/scripts/python/helpers/__pycache__/__init__.cpython-313.pyc +0 -0
  61. machineconfig/scripts/python/helpers/__pycache__/repo_sync_helpers.cpython-313.pyc +0 -0
  62. machineconfig/scripts/python/repos.py +10 -227
  63. machineconfig/scripts/python/repos_helper_record.py +193 -0
  64. machineconfig/scripts/windows/choose_wezterm_theme.ps1 +1 -1
  65. machineconfig/scripts/windows/cloud_copy.ps1 +1 -1
  66. machineconfig/scripts/windows/cloud_mount.ps1 +1 -1
  67. machineconfig/scripts/windows/cloud_repo_sync.ps1 +1 -1
  68. machineconfig/scripts/windows/cloud_sync.ps1 +1 -1
  69. machineconfig/scripts/windows/croshell.ps1 +1 -1
  70. machineconfig/scripts/windows/devops.ps1 +1 -29
  71. machineconfig/scripts/windows/dotfile.ps1 +1 -1
  72. machineconfig/scripts/windows/fire.ps1 +1 -45
  73. machineconfig/scripts/windows/ftpx.ps1 +1 -1
  74. machineconfig/scripts/windows/gpt.ps1 +1 -23
  75. machineconfig/scripts/windows/kill_process.ps1 +1 -1
  76. machineconfig/scripts/windows/mcinit.ps1 +1 -1
  77. machineconfig/scripts/windows/mount_ssh.ps1 +1 -1
  78. machineconfig/scripts/windows/pomodoro.ps1 +1 -1
  79. machineconfig/scripts/windows/repos.ps1 +1 -1
  80. machineconfig/scripts/windows/scheduler.ps1 +1 -1
  81. machineconfig/scripts/windows/snapshot.ps1 +1 -1
  82. machineconfig/scripts/windows/start_slidev.ps1 +1 -1
  83. machineconfig/scripts/windows/start_terminals.ps1 +1 -1
  84. machineconfig/scripts/windows/wifi_conn.ps1 +1 -2
  85. machineconfig/settings/shells/pwsh/init.ps1 +0 -4
  86. machineconfig/setup_linux/web_shortcuts/croshell.sh +1 -1
  87. machineconfig/setup_linux/web_shortcuts/interactive.sh +7 -13
  88. machineconfig/setup_windows/web_shortcuts/interactive.ps1 +9 -18
  89. machineconfig/setup_windows/wt_and_pwsh/set_wt_settings.py +1 -66
  90. machineconfig/utils/links.py +1 -2
  91. machineconfig/utils/options.py +8 -5
  92. machineconfig/utils/procs.py +5 -1
  93. machineconfig/utils/scheduling.py +0 -1
  94. machineconfig/{cluster/sessions_managers → utils/schemas/layouts}/layout_types.py +0 -1
  95. machineconfig/utils/schemas/repos/repos_types.py +28 -0
  96. machineconfig/utils/source_of_truth.py +1 -4
  97. machineconfig/utils/ssh.py +1 -1
  98. {machineconfig-2.6.dist-info → machineconfig-2.7.dist-info}/METADATA +1 -1
  99. {machineconfig-2.6.dist-info → machineconfig-2.7.dist-info}/RECORD +103 -110
  100. {machineconfig-2.6.dist-info → machineconfig-2.7.dist-info}/entry_points.txt +1 -1
  101. machineconfig/jobs/python_custom_installers/__pycache__/__init__.cpython-313.pyc +0 -0
  102. machineconfig/profile/create_hardlinks.py +0 -140
  103. machineconfig/scripts/linux/checkout_versions +0 -2
  104. machineconfig/scripts/linux/cloud_manager +0 -2
  105. machineconfig/scripts/linux/url2md +0 -2
  106. machineconfig/scripts/python/__pycache__/croshell.cpython-313.pyc +0 -0
  107. machineconfig/scripts/windows/checkout_version.ps1 +0 -1
  108. machineconfig/scripts/windows/cloud_manager.ps1 +0 -1
  109. machineconfig/scripts/windows/neofetch.ps1 +0 -2
  110. machineconfig/scripts/windows/wsl_windows_transfer.ps1 +0 -1
  111. machineconfig/settings/__pycache__/__init__.cpython-313.pyc +0 -0
  112. machineconfig/settings/shells/ipy/profiles/default/__pycache__/__init__.cpython-313.pyc +0 -0
  113. machineconfig/settings/shells/ipy/profiles/default/startup/__pycache__/__init__.cpython-313.pyc +0 -0
  114. machineconfig/utils/ai/browser_user_wrapper.py +0 -66
  115. machineconfig/utils/ai/url2md.py +0 -85
  116. /machineconfig/setup_windows/wt_and_pwsh/{set_pwsh_theme.py → install_nerd_fonts.py} +0 -0
  117. {machineconfig-2.6.dist-info → machineconfig-2.7.dist-info}/WHEEL +0 -0
  118. {machineconfig-2.6.dist-info → machineconfig-2.7.dist-info}/top_level.txt +0 -0
@@ -1,66 +0,0 @@
1
- # """
2
- # playwright install
3
- # sudo nala install libavif13
4
- # """
5
-
6
- # import os
7
- # os.environ["ANONYMIZED_TELEMETRY"] = "false"
8
-
9
- # from langchain_ollama import ChatOllama
10
- # from browser_use import Agent
11
- # import asyncio
12
- # from rich.panel import Panel
13
- # from rich import print as rprint
14
-
15
- # BOX_WIDTH = 150 # width for box drawing
16
-
17
-
18
- # def _get_padding(text: str, padding_before: int = 2, padding_after: int = 1) -> str:
19
- # """Calculate the padding needed to align the box correctly.
20
-
21
- # Args:
22
- # text: The text to pad
23
- # padding_before: The space taken before the text (usually "║ ")
24
- # padding_after: The space needed after the text (usually " ║")
25
-
26
- # Returns:
27
- # A string of spaces for padding
28
- # """
29
- # # Count visible characters (might not be perfect for all Unicode characters)
30
- # text_length = len(text)
31
- # padding_length = BOX_WIDTH - padding_before - text_length - padding_after
32
- # return ' ' * max(0, padding_length)
33
-
34
-
35
- # # Create agent with the model
36
- # async def main():
37
- # # header for browser automation agent
38
- # title = "🌐 Browser Automation Agent"
39
- # rprint(Panel(title, title="Status", width=BOX_WIDTH))
40
-
41
- # rprint("🔄 Initializing LLM model (llama3.1:8b)...")
42
- # llm = ChatOllama(model="llama3.1:8b")
43
- # rprint("✅ LLM model initialized")
44
-
45
- # task_line1 = "🤖 Task: Open https://chat.openai.com/ and ask how many r's in"
46
- # task_line2 = "rrraaararewey, use Thinking Button and type the answer"
47
- # task_content = f"{task_line1}\n{task_line2}"
48
- # rprint(Panel(task_content, title="Task", width=BOX_WIDTH))
49
-
50
- # rprint("🚀 Creating and launching browser agent...")
51
- # agent = Agent(
52
- # task="open https://chat.openai.com/ and ask how many r's in rrraaararewey, use Thinking Button and type the answer",
53
- # llm=llm
54
- # )
55
-
56
- # rprint("🏃‍♂️ Running agent task...")
57
- # await agent.run()
58
-
59
- # # footer success box
60
- # title = "✅ Browser automation task completed"
61
- # rprint(Panel(title, title="Status", width=BOX_WIDTH))
62
-
63
-
64
- # if __name__ == "__main__":
65
- # asyncio.run(main())
66
-
@@ -1,85 +0,0 @@
1
- from machineconfig.utils.utils2 import randstr
2
- from pathlib import Path
3
- import subprocess
4
- import multiprocessing
5
- import time
6
-
7
- cwd = Path.cwd()
8
-
9
- print("\n" + "=" * 50)
10
- print("🌐 Welcome to the URL to Markdown Converter")
11
- print("=" * 50 + "\n")
12
-
13
- tools_needed = ["xcrawl3r", "html2markdown"]
14
-
15
-
16
- url = input("🔗 Enter the URL: ")
17
- depth = input("🔍 Enter the crawl depth (default: 4): ") or "4"
18
-
19
- website_name_as_valid_filename = url.split("//")[-1].split("/")[0].replace(".", "_").replace(":", "_")
20
- domain = url.split("//")[-1].split("/")[0]
21
- op_dir = cwd.joinpath(".ai/website", website_name_as_valid_filename)
22
- op_dir.mkdir(exist_ok=True, parents=True)
23
- urls_file = op_dir.joinpath("urls", "urls.txt")
24
- urls_file.parent.mkdir(exist_ok=True, parents=True)
25
- # if urls_file.exists():
26
- # urls_file.unlink()
27
-
28
- print("🌐 Crawling the website to extract URLs...")
29
- command = f"""xcrawl3r --url {url} --domain {domain} --depth {depth} --concurrency 20 --parallelism 4 --output {urls_file} """
30
-
31
- try:
32
- print(f"Running command: {command}")
33
- subprocess.run(command, shell=True, check=True)
34
- except KeyboardInterrupt:
35
- if urls_file.exists():
36
- print("\n❌ Process interrupted by user, proceeding with existing URLs...")
37
- else:
38
- print("\n❌ Process interrupted by user, no URLs found.")
39
- exit(1)
40
-
41
- all_urls = urls_file.read_text(encoding="utf-8").splitlines()
42
- relevant_urls = list(set(all_urls)) # remove duplicates
43
- relevant_urls = [a_url for a_url in relevant_urls if not a_url.endswith(".css") and not a_url.endswith(".js") and not a_url.endswith(".png") and not a_url.endswith(".jpg") and not a_url.endswith(".jpeg") and not a_url.endswith(".gif")]
44
-
45
- print(f"✅ Found {len(relevant_urls)} relevant URLs. Preparing to convert to Markdown...\n")
46
-
47
- commands: list[str] = []
48
- for a_url in relevant_urls:
49
- commands.append(f"""curl {a_url} | html2markdown --output {op_dir.joinpath(a_url.split("/")[-1] + "_" + randstr(5) + ".md")} """)
50
-
51
-
52
- def run_command(cmd: str) -> bool:
53
- try:
54
- _result = subprocess.run(cmd, shell=True, check=True, capture_output=True, text=True)
55
- print(f"✅ Completed: {cmd[:60]} ...")
56
- return True
57
- except subprocess.SubprocessError as e:
58
- print(f"❌ Error with command: {cmd[:60]}...\n{str(e)}")
59
- return False
60
-
61
-
62
- def main():
63
- cpu_count = multiprocessing.cpu_count()
64
- max_processes = min(20, cpu_count)
65
- print(f"🚀 Running commands with {max_processes} parallel processes...\n")
66
-
67
- start_time = time.time()
68
-
69
- with multiprocessing.Pool(processes=max_processes) as pool:
70
- results = pool.map(run_command, commands)
71
-
72
- successful = results.count(True)
73
- failed = results.count(False)
74
- elapsed_time = time.time() - start_time
75
-
76
- print(f"\n⏱️ Completed in {elapsed_time:.2f} seconds")
77
- print(f"✅ Successfully processed: {successful} files")
78
- if failed > 0:
79
- print(f"❌ Failed to process: {failed} files")
80
-
81
- print(f"📂 Output saved to: {op_dir}\n")
82
-
83
-
84
- if __name__ == "__main__":
85
- main()