kkpyutil 1.50.1__py3-none-any.whl → 1.51.0__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: kkpyutil
3
- Version: 1.50.1
3
+ Version: 1.51.0
4
4
  Summary: Building blocks for sysadmin and DevOps
5
5
  Home-page: https://github.com/kakyoism/kkpyutil/
6
6
  License: MIT
@@ -0,0 +1,7 @@
1
+ kkpyutil.py,sha256=-ZQ-paLBQaADoO2HGKnuYK456bczu8dV8koxTOgZnAs,122735
2
+ kkpyutil_helper/windows/kkttssave.ps1,sha256=xa3-WzqNh2rGYlOx_I4ewOuCE94gkTO5cEwYH0M67_0,446
3
+ kkpyutil_helper/windows/kkttsspeak.ps1,sha256=7WUUHMmjTQroUWA2Mvdt4JtSt475nZUHQx-qP-7rS6o,305
4
+ kkpyutil-1.51.0.dist-info/LICENSE,sha256=uISevGnCxB5QOU0ftbofN75_yUtd6E2h_MWE1zqagC8,1065
5
+ kkpyutil-1.51.0.dist-info/METADATA,sha256=Eq-whzlPyrN0Sj_rf9sDCnzKk8V98HiTkYief8qimZk,1136
6
+ kkpyutil-1.51.0.dist-info/WHEEL,sha256=kLuE8m1WYU0Ig0_YEGrXyTtiJvKPpLpDEiChiNyei5Y,88
7
+ kkpyutil-1.51.0.dist-info/RECORD,,
kkpyutil.py CHANGED
@@ -3238,6 +3238,17 @@ def prompt_macos_admin_password(action="Your operation"):
3238
3238
  return None
3239
3239
 
3240
3240
 
3241
+ def join_unc_paths(*paths):
3242
+ # 1. Standardize all inputs to use backslashes and filter out empty strings
3243
+ segments = [str(p).replace('/', '\\').strip('\\') for p in paths if p]
3244
+
3245
+ # 2. Handle the leading slash: if the first input started with \, preserve it
3246
+ prefix = '\\' if paths[0].startswith(('\\', '/')) else ''
3247
+
3248
+ # 3. Join everything with single backslashes
3249
+ return prefix + '\\'.join(segments)
3250
+
3251
+
3241
3252
  # endregion
3242
3253
 
3243
3254
 
@@ -1,7 +0,0 @@
1
- kkpyutil.py,sha256=FDyp7KftZKUcfaGxQcIvrdis7QwttVlBRt5hcKMLh_U,122315
2
- kkpyutil_helper/windows/kkttssave.ps1,sha256=xa3-WzqNh2rGYlOx_I4ewOuCE94gkTO5cEwYH0M67_0,446
3
- kkpyutil_helper/windows/kkttsspeak.ps1,sha256=7WUUHMmjTQroUWA2Mvdt4JtSt475nZUHQx-qP-7rS6o,305
4
- kkpyutil-1.50.1.dist-info/LICENSE,sha256=uISevGnCxB5QOU0ftbofN75_yUtd6E2h_MWE1zqagC8,1065
5
- kkpyutil-1.50.1.dist-info/METADATA,sha256=1KVWiRwBrfGk3rnoClZHpay79eS5Lk5JucaPCVTetFs,1136
6
- kkpyutil-1.50.1.dist-info/WHEEL,sha256=kLuE8m1WYU0Ig0_YEGrXyTtiJvKPpLpDEiChiNyei5Y,88
7
- kkpyutil-1.50.1.dist-info/RECORD,,