minor-utils 0.2.0.dev1__tar.gz → 0.2.1.dev1__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.
@@ -0,0 +1,49 @@
1
+ Metadata-Version: 2.4
2
+ Name: minor_utils
3
+ Version: 0.2.1.dev1
4
+ Summary: Utils compilation for easier work
5
+ Author-email: CyberAxolotl <minor.gleb@outlook.com>
6
+ License-Expression: MIT
7
+ Requires-Python: >=3.10
8
+ Description-Content-Type: text/markdown
9
+
10
+ # minor-utils
11
+
12
+ Utility library for formatting and function management.
13
+
14
+ ## Installation
15
+
16
+ ```bash
17
+ pip install minor-utils
18
+ ```
19
+
20
+ ## Modules
21
+
22
+ ### Formatter
23
+ Format strings using built-in or custom formats. Supports pipelines, aliases, and enable/disable of formats.
24
+
25
+ ```python
26
+ from minor_utils import Formatter
27
+
28
+ Formatter.formatting("hello world", "camelCase") # "helloWorld"
29
+ Formatter.pipe("Hello World", "lower", "snake_case") # "hello_world"
30
+ ```
31
+
32
+ ### Manager
33
+ Register and manage functions with a menu-based runner.
34
+
35
+ ```python
36
+ from minor_utils import Manager
37
+
38
+ m = Manager()
39
+
40
+ @m.add_func
41
+ def greet():
42
+ print("Hello!")
43
+
44
+ m.run_manual()
45
+ ```
46
+
47
+ ## Note
48
+
49
+ The project is in early development. APIs may change, bugs are possible.
@@ -0,0 +1,40 @@
1
+ # minor-utils
2
+
3
+ Utility library for formatting and function management.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ pip install minor-utils
9
+ ```
10
+
11
+ ## Modules
12
+
13
+ ### Formatter
14
+ Format strings using built-in or custom formats. Supports pipelines, aliases, and enable/disable of formats.
15
+
16
+ ```python
17
+ from minor_utils import Formatter
18
+
19
+ Formatter.formatting("hello world", "camelCase") # "helloWorld"
20
+ Formatter.pipe("Hello World", "lower", "snake_case") # "hello_world"
21
+ ```
22
+
23
+ ### Manager
24
+ Register and manage functions with a menu-based runner.
25
+
26
+ ```python
27
+ from minor_utils import Manager
28
+
29
+ m = Manager()
30
+
31
+ @m.add_func
32
+ def greet():
33
+ print("Hello!")
34
+
35
+ m.run_manual()
36
+ ```
37
+
38
+ ## Note
39
+
40
+ The project is in early development. APIs may change, bugs are possible.
@@ -1,5 +1,7 @@
1
+ from importlib.metadata import version
2
+
1
3
  __title__ = "minor_utils"
2
- __version__ = "0.1.0"
4
+ __version__ = version("minor_utils")
3
5
  __author__ = "Gleb Minor"
4
6
  __license__ = "MIT"
5
7
 
@@ -71,8 +71,8 @@ class Formatter:
71
71
 
72
72
  formats = {
73
73
  "capitalize": cap,
74
- "up": up,
75
- "down": down,
74
+ "upper": up,
75
+ "lower": down,
76
76
  "spike": spike,
77
77
  "clean": clean,
78
78
  "camelCase": camel_case,
@@ -38,7 +38,7 @@ class Manager:
38
38
  if self.is_existing_func(func_name):
39
39
  raise InvalidArgumentError(f"Function '{func_name}' already exists in manager {self.__name}.")
40
40
 
41
- self.__funcs.append(func_name, f)
41
+ self.__funcs.append((func_name, f))
42
42
 
43
43
  return f
44
44
 
@@ -278,7 +278,7 @@ class Manager:
278
278
  results.setdefault(func_id, []).append(result)
279
279
  #--------
280
280
 
281
- # --------(Validation API)--------
281
+ #--------(Validation API)--------
282
282
  def is_existing_func(self, name):
283
283
  try:
284
284
  func_id = int(name)
@@ -0,0 +1,49 @@
1
+ Metadata-Version: 2.4
2
+ Name: minor_utils
3
+ Version: 0.2.1.dev1
4
+ Summary: Utils compilation for easier work
5
+ Author-email: CyberAxolotl <minor.gleb@outlook.com>
6
+ License-Expression: MIT
7
+ Requires-Python: >=3.10
8
+ Description-Content-Type: text/markdown
9
+
10
+ # minor-utils
11
+
12
+ Utility library for formatting and function management.
13
+
14
+ ## Installation
15
+
16
+ ```bash
17
+ pip install minor-utils
18
+ ```
19
+
20
+ ## Modules
21
+
22
+ ### Formatter
23
+ Format strings using built-in or custom formats. Supports pipelines, aliases, and enable/disable of formats.
24
+
25
+ ```python
26
+ from minor_utils import Formatter
27
+
28
+ Formatter.formatting("hello world", "camelCase") # "helloWorld"
29
+ Formatter.pipe("Hello World", "lower", "snake_case") # "hello_world"
30
+ ```
31
+
32
+ ### Manager
33
+ Register and manage functions with a menu-based runner.
34
+
35
+ ```python
36
+ from minor_utils import Manager
37
+
38
+ m = Manager()
39
+
40
+ @m.add_func
41
+ def greet():
42
+ print("Hello!")
43
+
44
+ m.run_manual()
45
+ ```
46
+
47
+ ## Note
48
+
49
+ The project is in early development. APIs may change, bugs are possible.
@@ -1,3 +1,4 @@
1
+ README.md
1
2
  pyproject.toml
2
3
  minor_utils/__init__.py
3
4
  minor_utils/errors.py
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "minor_utils"
7
- version = "0.2.0dev1"
7
+ version = "0.2.1dev1"
8
8
  description = "Utils compilation for easier work"
9
9
  authors = [{name = "CyberAxolotl", email = "minor.gleb@outlook.com"}]
10
10
  license = "MIT"
@@ -1,8 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: minor_utils
3
- Version: 0.2.0.dev1
4
- Summary: Utils compilation for easier work
5
- Author-email: CyberAxolotl <minor.gleb@outlook.com>
6
- License-Expression: MIT
7
- Requires-Python: >=3.10
8
- Description-Content-Type: text/markdown
@@ -1,8 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: minor_utils
3
- Version: 0.2.0.dev1
4
- Summary: Utils compilation for easier work
5
- Author-email: CyberAxolotl <minor.gleb@outlook.com>
6
- License-Expression: MIT
7
- Requires-Python: >=3.10
8
- Description-Content-Type: text/markdown