bluer-objects 6.37.1__tar.gz → 6.46.1__tar.gz

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.
Files changed (154) hide show
  1. {bluer_objects-6.37.1/bluer_objects.egg-info → bluer_objects-6.46.1}/PKG-INFO +2 -2
  2. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/README.md +1 -1
  3. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/alias.sh +1 -3
  4. bluer_objects-6.46.1/bluer_objects/.abcli/ls.sh +18 -0
  5. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage/clear.sh +2 -2
  6. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/help.sh +2 -2
  7. bluer_objects-6.46.1/bluer_objects/.abcli/tests/ls.sh +25 -0
  8. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/__init__.py +1 -1
  9. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/functions.py +2 -0
  10. bluer_objects-6.46.1/bluer_objects/help/ls.py +40 -0
  11. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/storage/WebDAV.py +8 -0
  12. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/storage/WebDAVzip.py +39 -0
  13. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/storage/__init__.py +12 -0
  14. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/storage/__main__.py +34 -1
  15. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/storage/base.py +9 -0
  16. {bluer_objects-6.37.1 → bluer_objects-6.46.1/bluer_objects.egg-info}/PKG-INFO +2 -2
  17. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects.egg-info/SOURCES.txt +1 -1
  18. bluer_objects-6.37.1/bluer_objects/.abcli/ls.sh +0 -24
  19. bluer_objects-6.37.1/bluer_objects/.abcli/publish.sh +0 -59
  20. bluer_objects-6.37.1/bluer_objects/.abcli/tests/ls.sh +0 -13
  21. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/LICENSE +0 -0
  22. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/MANIFEST.in +0 -0
  23. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/abcli.sh +0 -0
  24. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/actions.sh +0 -0
  25. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/aka.sh +0 -0
  26. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/bluer_objects.sh +0 -0
  27. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/clone.sh +0 -0
  28. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/download.sh +0 -0
  29. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/file.sh +0 -0
  30. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/gif.sh +0 -0
  31. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/host.sh +0 -0
  32. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/metadata/get.sh +0 -0
  33. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/metadata/post.sh +0 -0
  34. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/metadata.sh +0 -0
  35. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/browse.sh +0 -0
  36. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/cache.sh +0 -0
  37. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/list_registered_models.sh +0 -0
  38. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/log_artifacts.sh +0 -0
  39. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/log_run.sh +0 -0
  40. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/run.sh +0 -0
  41. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/tags/clone.sh +0 -0
  42. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/tags/get.sh +0 -0
  43. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/tags/search.sh +0 -0
  44. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/tags/set.sh +0 -0
  45. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/tags.sh +0 -0
  46. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/test.sh +0 -0
  47. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow/transition.sh +0 -0
  48. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/mlflow.sh +0 -0
  49. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/object.sh +0 -0
  50. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/select.sh +0 -0
  51. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage/download_file.sh +0 -0
  52. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage/exists.sh +0 -0
  53. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage/list.sh +0 -0
  54. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage/rm.sh +0 -0
  55. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage/status.sh +0 -0
  56. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/storage.sh +0 -0
  57. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/README.sh +0 -0
  58. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/clone.sh +0 -0
  59. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/gif.sh +0 -0
  60. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/host.sh +0 -0
  61. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/metadata.sh +0 -0
  62. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/mlflow_cache.sh +0 -0
  63. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/mlflow_logging.sh +0 -0
  64. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/mlflow_tags.sh +0 -0
  65. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/mlflow_test.sh +0 -0
  66. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/storage.sh +0 -0
  67. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/tests/version.sh +0 -0
  68. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/.abcli/upload.sh +0 -0
  69. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/README/__init__.py +0 -0
  70. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/README/functions.py +0 -0
  71. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/README/items.py +0 -0
  72. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/__main__.py +0 -0
  73. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/config.env +0 -0
  74. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/env.py +0 -0
  75. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/file/__init__.py +0 -0
  76. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/file/__main__.py +0 -0
  77. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/file/classes.py +0 -0
  78. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/file/functions.py +0 -0
  79. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/file/load.py +0 -0
  80. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/file/save.py +0 -0
  81. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/__init__.py +0 -0
  82. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/__main__.py +0 -0
  83. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/frame.py +0 -0
  84. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/gif.py +0 -0
  85. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/screen.py +0 -0
  86. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/signature.py +0 -0
  87. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/graphics/text.py +0 -0
  88. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/__init__.py +0 -0
  89. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/__main__.py +0 -0
  90. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/assets.py +0 -0
  91. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/clone.py +0 -0
  92. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/download.py +0 -0
  93. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/gif.py +0 -0
  94. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/host.py +0 -0
  95. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/metadata.py +0 -0
  96. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/mlflow/__init__.py +0 -0
  97. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/mlflow/cache.py +0 -0
  98. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/mlflow/tags.py +0 -0
  99. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/help/upload.py +0 -0
  100. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/host/__init__.py +0 -0
  101. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/host/__main__.py +0 -0
  102. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/host/functions.py +0 -0
  103. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/logger/__init__.py +0 -0
  104. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/logger/matrix.py +0 -0
  105. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/markdown.py +0 -0
  106. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/metadata/__init__.py +0 -0
  107. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/metadata/__main__.py +0 -0
  108. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/metadata/enums.py +0 -0
  109. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/metadata/get.py +0 -0
  110. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/metadata/post.py +0 -0
  111. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/__init__.py +0 -0
  112. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/__main__.py +0 -0
  113. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/cache.py +0 -0
  114. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/logging.py +0 -0
  115. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/models.py +0 -0
  116. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/objects.py +0 -0
  117. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/runs.py +0 -0
  118. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/tags.py +0 -0
  119. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/mlflow/testing.py +0 -0
  120. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/objects.py +0 -0
  121. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/path.py +0 -0
  122. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/sample.env +0 -0
  123. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/testing/__init__.py +0 -0
  124. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/testing/__main__.py +0 -0
  125. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/testing/functions.py +0 -0
  126. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/__init__.py +0 -0
  127. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_README.py +0 -0
  128. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_env.py +0 -0
  129. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_file_load_save.py +0 -0
  130. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_fullname.py +0 -0
  131. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_graphics.py +0 -0
  132. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_graphics_frame.py +0 -0
  133. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_graphics_gif.py +0 -0
  134. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_graphics_screen.py +0 -0
  135. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_graphics_signature.py +0 -0
  136. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_graphics_text.py +0 -0
  137. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_logger.py +0 -0
  138. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_logger_matrix.py +0 -0
  139. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_markdown.py +0 -0
  140. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_metadata.py +0 -0
  141. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_mlflow.py +0 -0
  142. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_objects.py +0 -0
  143. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_path.py +0 -0
  144. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_storage.py +0 -0
  145. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_testing.py +0 -0
  146. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/tests/test_version.py +0 -0
  147. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects/urls.py +0 -0
  148. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects.egg-info/dependency_links.txt +0 -0
  149. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects.egg-info/requires.txt +0 -0
  150. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/bluer_objects.egg-info/top_level.txt +0 -0
  151. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/pyproject.toml +0 -0
  152. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/requirements.txt +0 -0
  153. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/setup.cfg +0 -0
  154. {bluer_objects-6.37.1 → bluer_objects-6.46.1}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: bluer_objects
3
- Version: 6.37.1
3
+ Version: 6.46.1
4
4
  Summary: 🌀 data objects for Bash.
5
5
  Home-page: https://github.com/kamangir/bluer-objects
6
6
  Author: Arash Abadpour (Kamangir)
@@ -53,6 +53,6 @@ Also home to [blue README](https://github.com/kamangir/bluer-objects/blob/main/b
53
53
 
54
54
  [![pylint](https://github.com/kamangir/bluer-objects/actions/workflows/pylint.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/pylint.yml) [![pytest](https://github.com/kamangir/bluer-objects/actions/workflows/pytest.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/pytest.yml) [![bashtest](https://github.com/kamangir/bluer-objects/actions/workflows/bashtest.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/bashtest.yml) [![PyPI version](https://img.shields.io/pypi/v/bluer-objects.svg)](https://pypi.org/project/bluer-objects/) [![PyPI - Downloads](https://img.shields.io/pypi/dd/bluer-objects)](https://pypistats.org/packages/bluer-objects)
55
55
 
56
- built by 🌀 [`bluer_options-5.28.1`](https://github.com/kamangir/awesome-bash-cli), based on 🌀 [`bluer_objects-6.37.1`](https://github.com/kamangir/bluer-objects).
56
+ built by 🌀 [`bluer_options-5.43.1`](https://github.com/kamangir/awesome-bash-cli), based on 🌀 [`bluer_objects-6.46.1`](https://github.com/kamangir/bluer-objects).
57
57
 
58
58
  built by 🌀 [`blueness-3.96.1`](https://github.com/kamangir/blueness).
@@ -19,4 +19,4 @@ Also home to [blue README](./bluer_objects/README/).
19
19
 
20
20
  [![pylint](https://github.com/kamangir/bluer-objects/actions/workflows/pylint.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/pylint.yml) [![pytest](https://github.com/kamangir/bluer-objects/actions/workflows/pytest.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/pytest.yml) [![bashtest](https://github.com/kamangir/bluer-objects/actions/workflows/bashtest.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/bashtest.yml) [![PyPI version](https://img.shields.io/pypi/v/bluer-objects.svg)](https://pypi.org/project/bluer-objects/) [![PyPI - Downloads](https://img.shields.io/pypi/dd/bluer-objects)](https://pypistats.org/packages/bluer-objects)
21
21
 
22
- built by 🌀 [`bluer_options-5.28.1`](https://github.com/kamangir/awesome-bash-cli), based on 🌀 [`bluer_objects-6.37.1`](https://github.com/kamangir/bluer-objects).
22
+ built by 🌀 [`bluer_options-5.43.1`](https://github.com/kamangir/awesome-bash-cli), based on 🌀 [`bluer_objects-6.46.1`](https://github.com/kamangir/bluer-objects).
@@ -19,7 +19,7 @@ alias @file=bluer_objects_file
19
19
 
20
20
  alias @host=bluer_objects_host
21
21
 
22
- alias @ls=bluer_ai_ls
22
+ alias @ls=bluer_objects_ls
23
23
 
24
24
  alias @metadata=bluer_objects_metadata
25
25
 
@@ -29,8 +29,6 @@ alias @mysql=abcli_mysql
29
29
 
30
30
  alias @objects=bluer_objects
31
31
 
32
- alias @publish=bluer_ai_publish
33
-
34
32
  alias @select=bluer_ai_select
35
33
 
36
34
  alias @upload=bluer_objects_upload
@@ -0,0 +1,18 @@
1
+ #! /usr/bin/env bash
2
+
3
+ function bluer_objects_ls() {
4
+ local options=$1
5
+ local where=$(abcli_option_choice "$options" cloud,local)
6
+
7
+ if [[ -z "$where" ]]; then
8
+ ls -1 "$@"
9
+ else
10
+ local object_name=$(abcli_clarify_object $2 .)
11
+
12
+ python3 -m bluer_objects.storage \
13
+ ls \
14
+ --object_name $object_name \
15
+ --where $where \
16
+ "${@:3}"
17
+ fi
18
+ }
@@ -12,7 +12,7 @@ function bluer_ai_storage_clear() {
12
12
 
13
13
  local recent_filename=$ABCLI_OBJECT_ROOT/QGIS-recent.yaml
14
14
  if [[ ! -f "$recent_filename" ]]; then
15
- abcli_log_warning "run \"QGIS.list_recent_projects\" first."
15
+ bluer_ai_log_warning "run \"QGIS.list_recent_projects\" first."
16
16
  return 1
17
17
  fi
18
18
 
@@ -30,7 +30,7 @@ function bluer_ai_storage_clear() {
30
30
  if [[ "+$recent_projects+" == *"+$object_name+"* ]]; then
31
31
  abcli_log "will keep $object_name ..."
32
32
  else
33
- abcli_log_warning "will delete $object_name ..."
33
+ bluer_ai_log_warning "will delete $object_name ..."
34
34
 
35
35
  [[ "$do_dryrun" == 0 ]] &&
36
36
  rm -rfv $object_name
@@ -31,6 +31,8 @@ function test_bluer_objects_help() {
31
31
  \
32
32
  "@gif" \
33
33
  \
34
+ "@ls" \
35
+ \
34
36
  "@host" \
35
37
  "@host get" \
36
38
  "@host reboot" \
@@ -58,8 +60,6 @@ function test_bluer_objects_help() {
58
60
  "@mlflow test" \
59
61
  "@mlflow transition" \
60
62
  \
61
- "@publish" \
62
- \
63
63
  "@select" \
64
64
  \
65
65
  "@storage" \
@@ -0,0 +1,25 @@
1
+ #! /usr/bin/env bash
2
+
3
+ function test_bluer_objects_ls() {
4
+ local object_name=test_bluer_objects_ls-$(abcli_string_timestamp_short)
5
+
6
+ python3 -m bluer_objects.testing \
7
+ create_test_asset \
8
+ --object_name $object_name
9
+ [[ $? -ne 0 ]] && return 1
10
+ abcli_hr
11
+
12
+ bluer_objects_upload - $object_name
13
+ [[ $? -ne 0 ]] && return 1
14
+ abcli_hr
15
+
16
+ bluer_objects_ls cloud $object_name
17
+ [[ $? -ne 0 ]] && return 1
18
+ abcli_hr
19
+
20
+ bluer_objects_ls local $object_name
21
+ [[ $? -ne 0 ]] && return 1
22
+ abcli_hr
23
+
24
+ bluer_objects_ls $abcli_path_bash/tests/
25
+ }
@@ -4,7 +4,7 @@ ICON = "🌀"
4
4
 
5
5
  DESCRIPTION = f"{ICON} data objects for Bash."
6
6
 
7
- VERSION = "6.37.1"
7
+ VERSION = "6.46.1"
8
8
 
9
9
  REPO_NAME = "bluer-objects"
10
10
 
@@ -6,6 +6,7 @@ from bluer_objects.help.clone import help_clone
6
6
  from bluer_objects.help.download import help_download
7
7
  from bluer_objects.help.gif import help_gif
8
8
  from bluer_objects.help.host import help_functions as help_host
9
+ from bluer_objects.help.ls import help_ls
9
10
  from bluer_objects.help.metadata import help_functions as help_metadata
10
11
  from bluer_objects.help.mlflow import help_functions as help_mlflow
11
12
  from bluer_objects.help.upload import help_upload
@@ -19,6 +20,7 @@ help_functions.update(
19
20
  "download": help_download,
20
21
  "gif": help_gif,
21
22
  "host": help_host,
23
+ "ls": help_ls,
22
24
  "metadata": help_metadata,
23
25
  "mlflow": help_mlflow,
24
26
  "upload": help_upload,
@@ -0,0 +1,40 @@
1
+ from typing import List
2
+
3
+ from bluer_options.terminal import show_usage
4
+
5
+
6
+ def help_ls(
7
+ tokens: List[str],
8
+ mono: bool,
9
+ ) -> str:
10
+ args = [
11
+ "[--delim <space>]",
12
+ "[--log <0>]",
13
+ ]
14
+
15
+ usage_1 = show_usage(
16
+ [
17
+ "@ls",
18
+ "cloud | local",
19
+ "<object-name>",
20
+ ]
21
+ + args,
22
+ "ls <object-name>.",
23
+ mono=mono,
24
+ )
25
+
26
+ usage_2 = show_usage(
27
+ [
28
+ "@ls",
29
+ "<path>",
30
+ ],
31
+ "ls <path>.",
32
+ mono=mono,
33
+ )
34
+
35
+ return "\n".join(
36
+ [
37
+ usage_1,
38
+ usage_2,
39
+ ]
40
+ )
@@ -1,3 +1,4 @@
1
+ from typing import List, Tuple
1
2
  from webdav3.client import Client
2
3
 
3
4
  from bluer_objects.storage.base import StorageInterface
@@ -81,6 +82,13 @@ class WebDAVInterface(StorageInterface):
81
82
  log=log,
82
83
  )
83
84
 
85
+ def ls(
86
+ self,
87
+ object_name: str,
88
+ where: str = "local",
89
+ ) -> Tuple[bool, List[str]]:
90
+ assert False, "not implemented"
91
+
84
92
  def upload(
85
93
  self,
86
94
  object_name: str,
@@ -1,3 +1,6 @@
1
+ import glob
2
+ import os
3
+ from typing import Tuple, List
1
4
  from webdav3.client import Client
2
5
 
3
6
  from bluer_objects.storage.base import StorageInterface
@@ -60,6 +63,42 @@ class WebDAVzipInterface(StorageInterface):
60
63
  log=log,
61
64
  )
62
65
 
66
+ def ls(
67
+ self,
68
+ object_name: str,
69
+ where: str = "local",
70
+ ) -> Tuple[bool, List[str]]:
71
+ if where == "local":
72
+ object_path = objects.object_path(
73
+ object_name=object_name,
74
+ )
75
+
76
+ return True, [
77
+ os.path.relpath(filename, start=object_path)
78
+ for filename in glob.glob(
79
+ os.path.join(
80
+ object_path,
81
+ "**",
82
+ "*",
83
+ ),
84
+ recursive=True,
85
+ )
86
+ if os.path.isfile(filename)
87
+ ]
88
+
89
+ if where == "cloud":
90
+ try:
91
+ if self.client.check(remote_path=f"{object_name}.zip"):
92
+ return True, [f"{object_name}.zip"]
93
+ except Exception as e:
94
+ logger.error(e)
95
+ return False, []
96
+
97
+ return True, []
98
+
99
+ logger.error(f"Unknown 'where': {where}")
100
+ return False, []
101
+
63
102
  def upload(
64
103
  self,
65
104
  object_name: str,
@@ -1,3 +1,5 @@
1
+ from typing import Tuple, List
2
+
1
3
  from bluer_objects.storage.base import StorageInterface
2
4
  from bluer_objects.storage.WebDAV import WebDAVInterface
3
5
  from bluer_objects.storage.WebDAVzip import WebDAVzipInterface
@@ -27,6 +29,16 @@ def download(
27
29
  )
28
30
 
29
31
 
32
+ def ls(
33
+ object_name: str,
34
+ where: str = "local",
35
+ ) -> Tuple[bool, List[str]]:
36
+ return interface.ls(
37
+ object_name=object_name,
38
+ where=where,
39
+ )
40
+
41
+
30
42
  def upload(
31
43
  object_name: str,
32
44
  filename: str = "",
@@ -13,7 +13,7 @@ parser = argparse.ArgumentParser(NAME)
13
13
  parser.add_argument(
14
14
  "task",
15
15
  type=str,
16
- help="download | upload",
16
+ help="download | ls | upload",
17
17
  )
18
18
  parser.add_argument(
19
19
  "--object_name",
@@ -24,8 +24,26 @@ parser.add_argument(
24
24
  type=str,
25
25
  default="",
26
26
  )
27
+ parser.add_argument(
28
+ "--where",
29
+ type=str,
30
+ default="local",
31
+ help="local | cloud",
32
+ )
33
+ parser.add_argument(
34
+ "--log",
35
+ type=int,
36
+ default=1,
37
+ help="0|1",
38
+ )
39
+ parser.add_argument(
40
+ "--delim",
41
+ type=str,
42
+ default=",",
43
+ )
27
44
  args = parser.parse_args()
28
45
 
46
+ delim = " " if args.delim == "space" else args.delim
29
47
 
30
48
  success = False
31
49
  if args.task == "download":
@@ -33,6 +51,21 @@ if args.task == "download":
33
51
  object_name=args.object_name,
34
52
  filename=args.filename,
35
53
  )
54
+ elif args.task == "ls":
55
+ success, list_of_files = storage.ls(
56
+ object_name=args.object_name,
57
+ where=args.where,
58
+ )
59
+
60
+ if args.log:
61
+ logger.info(
62
+ "{:,} file(s).".format(len(list_of_files)),
63
+ )
64
+ for index, filename in enumerate(list_of_files):
65
+ logger.info(f"#{index+1: 4d} - {filename}")
66
+ else:
67
+ print(delim.join(list_of_files))
68
+
36
69
  elif args.task == "upload":
37
70
  success = storage.upload(
38
71
  object_name=args.object_name,
@@ -1,3 +1,5 @@
1
+ from typing import Tuple, List
2
+
1
3
  from bluer_objects.logger import logger
2
4
 
3
5
 
@@ -19,6 +21,13 @@ class StorageInterface:
19
21
 
20
22
  return True
21
23
 
24
+ def ls(
25
+ self,
26
+ object_name: str,
27
+ where: str = "local",
28
+ ) -> Tuple[bool, List[str]]:
29
+ return True, []
30
+
22
31
  def upload(
23
32
  self,
24
33
  object_name: str,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: bluer_objects
3
- Version: 6.37.1
3
+ Version: 6.46.1
4
4
  Summary: 🌀 data objects for Bash.
5
5
  Home-page: https://github.com/kamangir/bluer-objects
6
6
  Author: Arash Abadpour (Kamangir)
@@ -53,6 +53,6 @@ Also home to [blue README](https://github.com/kamangir/bluer-objects/blob/main/b
53
53
 
54
54
  [![pylint](https://github.com/kamangir/bluer-objects/actions/workflows/pylint.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/pylint.yml) [![pytest](https://github.com/kamangir/bluer-objects/actions/workflows/pytest.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/pytest.yml) [![bashtest](https://github.com/kamangir/bluer-objects/actions/workflows/bashtest.yml/badge.svg)](https://github.com/kamangir/bluer-objects/actions/workflows/bashtest.yml) [![PyPI version](https://img.shields.io/pypi/v/bluer-objects.svg)](https://pypi.org/project/bluer-objects/) [![PyPI - Downloads](https://img.shields.io/pypi/dd/bluer-objects)](https://pypistats.org/packages/bluer-objects)
55
55
 
56
- built by 🌀 [`bluer_options-5.28.1`](https://github.com/kamangir/awesome-bash-cli), based on 🌀 [`bluer_objects-6.37.1`](https://github.com/kamangir/bluer-objects).
56
+ built by 🌀 [`bluer_options-5.43.1`](https://github.com/kamangir/awesome-bash-cli), based on 🌀 [`bluer_objects-6.46.1`](https://github.com/kamangir/bluer-objects).
57
57
 
58
58
  built by 🌀 [`blueness-3.96.1`](https://github.com/kamangir/blueness).
@@ -32,7 +32,6 @@ bluer_objects/.abcli/ls.sh
32
32
  bluer_objects/.abcli/metadata.sh
33
33
  bluer_objects/.abcli/mlflow.sh
34
34
  bluer_objects/.abcli/object.sh
35
- bluer_objects/.abcli/publish.sh
36
35
  bluer_objects/.abcli/select.sh
37
36
  bluer_objects/.abcli/storage.sh
38
37
  bluer_objects/.abcli/upload.sh
@@ -94,6 +93,7 @@ bluer_objects/help/download.py
94
93
  bluer_objects/help/functions.py
95
94
  bluer_objects/help/gif.py
96
95
  bluer_objects/help/host.py
96
+ bluer_objects/help/ls.py
97
97
  bluer_objects/help/metadata.py
98
98
  bluer_objects/help/upload.py
99
99
  bluer_objects/help/mlflow/__init__.py
@@ -1,24 +0,0 @@
1
- #! /usr/bin/env bash
2
-
3
- function bluer_ai_ls() {
4
- local options=$1
5
- local on_cloud=$(abcli_option_int "$options" cloud 0)
6
- local on_local=$(abcli_option_int "$options" local 0)
7
-
8
- [[ "$on_cloud" == 1 ]] ||
9
- [[ "$on_local" == 1 ]] &&
10
- local object_name=$(abcli_clarify_object $2 .)
11
-
12
- if [ "$on_cloud" == 1 ]; then
13
- abcli_eval - \
14
- aws s3 ls $ABCLI_S3_OBJECT_PREFIX/$object_name/
15
- elif [ "$on_local" == 1 ]; then
16
- abcli_eval - \
17
- ls -1lh $ABCLI_OBJECT_ROOT/$object_name
18
- else
19
- abcli_eval - \
20
- ls -1 "$@"
21
- fi
22
-
23
- return 0
24
- }
@@ -1,59 +0,0 @@
1
- #! /usr/bin/env bash
2
-
3
- function bluer_ai_publish() {
4
- local options=$1
5
- local do_download=$(abcli_option_int "$options" download 1)
6
- local do_tar=$(abcli_option_int "$options" tar 0)
7
- local prefix=$(abcli_option "$options" prefix)
8
- local suffix=$(abcli_option "$options" suffix)
9
-
10
- local object_name=$(abcli_clarify_object $2 .)
11
- [[ "$do_download" == 1 ]] &&
12
- bluer_objects_download - $object_name
13
-
14
- bluer_objects_mlflow_tags set $object_name published
15
-
16
- local public_object_name=$(abcli_option "$options" as $object_name)
17
-
18
- if [ "$do_tar" == 1 ]; then
19
- abcli_log "publishing $object_name -> $public_object_name.tar.gz"
20
-
21
- bluer_objects_upload ~open,solid $object_name
22
- aws s3 cp \
23
- $ABCLI_S3_OBJECT_PREFIX/$object_name.tar.gz \
24
- s3://$ABCLI_AWS_S3_PUBLIC_BUCKET_NAME/$public_object_name.tar.gz
25
- aws s3 rm \
26
- $ABCLI_S3_OBJECT_PREFIX/$object_name.tar.gz
27
-
28
- abcli_log "🔗 $ABCLI_PUBLIC_PREFIX/$public_object_name.tar.gz"
29
- return
30
- fi
31
-
32
- local object_path=$ABCLI_OBJECT_ROOT/$object_name
33
-
34
- if [[ -z "$prefix$suffix" ]]; then
35
- abcli_log "publishing $object_name -> $public_object_name"
36
-
37
- aws s3 sync \
38
- $object_path/ \
39
- s3://$ABCLI_AWS_S3_PUBLIC_BUCKET_NAME/$public_object_name/
40
-
41
- abcli_log "🔗 $ABCLI_PUBLIC_PREFIX/$public_object_name/"
42
- return
43
- fi
44
-
45
- abcli_log "publishing $object_name/$prefix*$suffix -> $public_object_name"
46
-
47
- pushd $object_path >/dev/null
48
- local filename
49
- for filename in $(ls *); do
50
- [[ "$filename" != "$prefix"*"$suffix" ]] && continue
51
-
52
- aws s3 cp \
53
- $filename \
54
- s3://$ABCLI_AWS_S3_PUBLIC_BUCKET_NAME/$public_object_name/$filename
55
-
56
- abcli_log "🔗 $ABCLI_PUBLIC_PREFIX/$public_object_name/$filename"
57
- done
58
- popd >/dev/null
59
- }
@@ -1,13 +0,0 @@
1
- #! /usr/bin/env bash
2
-
3
- function test_bluer_objects_ls() {
4
- bluer_ai_select
5
-
6
- bluer_objects_upload
7
-
8
- bluer_ai_ls cloud
9
-
10
- bluer_ai_ls local
11
-
12
- bluer_ai_ls "$abcli_path_bash/tests/*.sh"
13
- }
File without changes
File without changes
File without changes