python-snacks 0.1.3__tar.gz → 0.1.4__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-snacks
3
- Version: 0.1.3
3
+ Version: 0.1.4
4
4
  Summary: A CLI tool for managing a personal stash of reusable Python code snippets.
5
5
  Requires-Python: >=3.10
6
6
  Description-Content-Type: text/markdown
@@ -10,12 +10,12 @@ Provides-Extra: test
10
10
  Requires-Dist: pytest>=8; extra == "test"
11
11
  Dynamic: license-file
12
12
 
13
- # Snack Stash
13
+ # python-snacks
14
14
 
15
15
  A personal CLI tool for managing a local stash of reusable Python code snippets. Browse, copy, and curate snippets across projects with a single command.
16
16
 
17
17
  ```bash
18
- pipx install snack-stash
18
+ pipx install python-snacks
19
19
  snack stash create default ~/snack-stash
20
20
  snack unpack auth/google_oauth.py
21
21
  ```
@@ -26,16 +26,22 @@ snack unpack auth/google_oauth.py
26
26
 
27
27
  **Recommended (pipx):**
28
28
  ```bash
29
- pipx install snack-stash
29
+ pipx install python-snacks
30
30
  ```
31
31
 
32
32
  **Alternative (pip):**
33
33
  ```bash
34
- pip install snack-stash
34
+ pip install python-snacks
35
35
  ```
36
36
 
37
37
  Requires Python 3.10+.
38
38
 
39
+ **Updating:**
40
+ ```bash
41
+ pipx upgrade python-snacks # if installed with pipx
42
+ pip install --upgrade python-snacks # if installed with pip
43
+ ```
44
+
39
45
  ---
40
46
 
41
47
  ## Configuration
@@ -1,9 +1,9 @@
1
- # Snack Stash
1
+ # python-snacks
2
2
 
3
3
  A personal CLI tool for managing a local stash of reusable Python code snippets. Browse, copy, and curate snippets across projects with a single command.
4
4
 
5
5
  ```bash
6
- pipx install snack-stash
6
+ pipx install python-snacks
7
7
  snack stash create default ~/snack-stash
8
8
  snack unpack auth/google_oauth.py
9
9
  ```
@@ -14,16 +14,22 @@ snack unpack auth/google_oauth.py
14
14
 
15
15
  **Recommended (pipx):**
16
16
  ```bash
17
- pipx install snack-stash
17
+ pipx install python-snacks
18
18
  ```
19
19
 
20
20
  **Alternative (pip):**
21
21
  ```bash
22
- pip install snack-stash
22
+ pip install python-snacks
23
23
  ```
24
24
 
25
25
  Requires Python 3.10+.
26
26
 
27
+ **Updating:**
28
+ ```bash
29
+ pipx upgrade python-snacks # if installed with pipx
30
+ pip install --upgrade python-snacks # if installed with pip
31
+ ```
32
+
27
33
  ---
28
34
 
29
35
  ## Configuration
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "python-snacks"
7
- version = "0.1.3"
7
+ version = "0.1.4"
8
8
  description = "A CLI tool for managing a personal stash of reusable Python code snippets."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-snacks
3
- Version: 0.1.3
3
+ Version: 0.1.4
4
4
  Summary: A CLI tool for managing a personal stash of reusable Python code snippets.
5
5
  Requires-Python: >=3.10
6
6
  Description-Content-Type: text/markdown
@@ -10,12 +10,12 @@ Provides-Extra: test
10
10
  Requires-Dist: pytest>=8; extra == "test"
11
11
  Dynamic: license-file
12
12
 
13
- # Snack Stash
13
+ # python-snacks
14
14
 
15
15
  A personal CLI tool for managing a local stash of reusable Python code snippets. Browse, copy, and curate snippets across projects with a single command.
16
16
 
17
17
  ```bash
18
- pipx install snack-stash
18
+ pipx install python-snacks
19
19
  snack stash create default ~/snack-stash
20
20
  snack unpack auth/google_oauth.py
21
21
  ```
@@ -26,16 +26,22 @@ snack unpack auth/google_oauth.py
26
26
 
27
27
  **Recommended (pipx):**
28
28
  ```bash
29
- pipx install snack-stash
29
+ pipx install python-snacks
30
30
  ```
31
31
 
32
32
  **Alternative (pip):**
33
33
  ```bash
34
- pip install snack-stash
34
+ pip install python-snacks
35
35
  ```
36
36
 
37
37
  Requires Python 3.10+.
38
38
 
39
+ **Updating:**
40
+ ```bash
41
+ pipx upgrade python-snacks # if installed with pipx
42
+ pip install --upgrade python-snacks # if installed with pip
43
+ ```
44
+
39
45
  ---
40
46
 
41
47
  ## Configuration
@@ -22,7 +22,7 @@ app = typer.Typer(
22
22
  def _version_callback(value: bool) -> None:
23
23
  if value:
24
24
  version = importlib.metadata.version("python-snacks")
25
- typer.echo(f"snack-stash v{version}")
25
+ typer.echo(f"python-snacks v{version}")
26
26
  raise typer.Exit()
27
27
 
28
28
 
@@ -68,7 +68,7 @@ def list_snacks(
68
68
  snippets = sorted(
69
69
  p.relative_to(stash).as_posix()
70
70
  for p in stash.rglob("*.py")
71
- if not p.name.startswith("_")
71
+ if not any(part.startswith(("_", ".")) for part in p.relative_to(stash).parts)
72
72
  )
73
73
  if category:
74
74
  snippets = [s for s in snippets if s.startswith(f"{category}/")]
@@ -84,7 +84,8 @@ def search(
84
84
  matches = sorted(
85
85
  p.relative_to(stash).as_posix()
86
86
  for p in stash.rglob("*.py")
87
- if keyword.lower() in p.name.lower() and not p.name.startswith("_")
87
+ if keyword.lower() in p.name.lower()
88
+ and not any(part.startswith(("_", ".")) for part in p.relative_to(stash).parts)
88
89
  )
89
90
  typer.echo("\n".join(matches) if matches else f"No snippets matching '{keyword}'.")
90
91
 
File without changes
File without changes