ignore-python 0.3.3__cp314-cp314-win_arm64.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.
ignore/__init__.py ADDED
@@ -0,0 +1 @@
1
+ from .ignore import *
ignore/__init__.pyi ADDED
@@ -0,0 +1,50 @@
1
+ import pathlib
2
+ from typing import Self
3
+
4
+ from ignore.overrides import Override
5
+
6
+ class Error(Exception):
7
+ """
8
+ Represents an error that can occur during operations.
9
+ """
10
+
11
+ class IOError(Exception):
12
+ """
13
+ An error that occurs when doing I/O.
14
+
15
+ Currently, the only case where this error is used is for operating system errors of type `ENOENT`.
16
+ """
17
+
18
+ errno: int
19
+
20
+ filename: str
21
+
22
+ def __init__(self, errno: int, strerror: str, filename: str) -> None: ...
23
+
24
+ class DirEntry:
25
+ def path(self) -> pathlib.Path: ...
26
+ def depth(self) -> int: ...
27
+
28
+ class Walk:
29
+ def __init__(self, path: pathlib.Path) -> None: ...
30
+ def __iter__(self) -> Self: ...
31
+ def __next__(self) -> DirEntry: ...
32
+
33
+ class WalkBuilder:
34
+ def __init__(self, path: pathlib.Path) -> None: ...
35
+ def hidden(self, yes: bool) -> Self: ...
36
+ def ignore(self, yes: bool) -> Self: ...
37
+ def parents(self, yes: bool) -> Self: ...
38
+ def git_ignore(self, yes: bool) -> Self: ...
39
+ def git_global(self, yes: bool) -> Self: ...
40
+ def git_exclude(self, yes: bool) -> Self: ...
41
+ def require_git(self, yes: bool) -> Self: ...
42
+ def overrides(self, overrides: Override) -> Self: ...
43
+ def follow_links(self, yes: bool) -> Self: ...
44
+ def same_file_system(self, yes: bool) -> Self: ...
45
+ def max_depth(self, depth: int | None) -> Self: ...
46
+ def max_filesize(self, filesize: int | None) -> Self: ...
47
+ def add_custom_ignore_filename(self, file_name: str) -> Self: ...
48
+ def add(self, path: pathlib.Path) -> Self: ...
49
+ def add_ignore(self, path: pathlib.Path) -> None: ...
50
+ def build(self) -> Walk: ...
Binary file
@@ -0,0 +1,9 @@
1
+ import pathlib
2
+ from typing import Self
3
+
4
+ class Override: ...
5
+
6
+ class OverrideBuilder:
7
+ def __init__(self, path: pathlib.Path) -> None: ...
8
+ def build(self) -> Override: ...
9
+ def add(self, glob: str) -> Self: ...
File without changes
ignore/py.typed ADDED
File without changes
@@ -0,0 +1,66 @@
1
+ Metadata-Version: 2.4
2
+ Name: ignore-python
3
+ Version: 0.3.3
4
+ Classifier: Programming Language :: Rust
5
+ Classifier: Programming Language :: Python :: Implementation :: CPython
6
+ Classifier: Programming Language :: Python :: Implementation :: PyPy
7
+ License-File: LICENSE.txt
8
+ Summary: Python bindings for the Rust crate ignore
9
+ Keywords: python,gitignore,search,rust,extension,module,filesystem,recursively-search,fd,ripgrep,ignore
10
+ Requires-Python: >=3.8
11
+ Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
12
+ Project-URL: documentation, https://borsattoz.github.io/ignore-python
13
+ Project-URL: repository, https://github.com/borsattoz/ignore-python
14
+
15
+ # ignore in Python
16
+ This is a Python library that binds to the Rust crate
17
+ [ignore](https://github.com/BurntSushi/ripgrep/tree/master/crates/ignore).
18
+
19
+ ignore's Python bindings can be used for building a fast recursive
20
+ directory iterator that respects various filters such as globs, file
21
+ types and `.gitignore` files.
22
+
23
+ ## Example
24
+ This example shows the most basic usage of this package. This code
25
+ will recursively traverse the current directory while automatically
26
+ filtering out files and directories according to ignore globs found in
27
+ files like `.ignore` and `.gitignore`:
28
+
29
+ ```python
30
+ from ignore import Walk
31
+
32
+ for entry in Walk("./"):
33
+ print(entry.path())
34
+ ```
35
+
36
+ ## Example: advanced
37
+ By default, the recursive directory iterator will ignore hidden files and directories. This can be disabled by building the iterator with `WalkBuilder`:
38
+
39
+ ```python
40
+ from ignore import WalkBuilder
41
+
42
+ for entry in WalkBuilder("./").hidden(False).build():
43
+ print(entry.path())
44
+ ```
45
+
46
+ Refer to the [API documentation](https://borsattoz.github.io/ignore-python) for more information.
47
+
48
+ ## How to install
49
+ ### On Arch Linux
50
+ You can install the [python-ignore package](https://archlinux.org/packages/extra/x86_64/python-ignore/) from the official repos:
51
+ ```sh
52
+ pacman -S python-ignore
53
+ ```
54
+ ### From pip
55
+ You can install the [ignore-python package](https://pypi.org/project/ignore-python/):
56
+ ```sh
57
+ pip install ignore-python
58
+ # or
59
+ python -m pip install ignore-python
60
+ ```
61
+
62
+ ## How to develop
63
+ This assumes that you have rust and cargo installed. I use the
64
+ workflow recommended by [pyo3](https://github.com/PyO3/pyo3) and
65
+ [maturin](https://github.com/PyO3/maturin).
66
+
@@ -0,0 +1,11 @@
1
+ ignore/__init__.py,sha256=M5KX00vnQSTlKos8XxRuiwKu0A5rzv2qRPMdcrjx4uY,23
2
+ ignore/__init__.pyi,sha256=J-U23g-X31-2QQ-El0e4ud8Q-kDD92Foe3H9nwiB0sE,1667
3
+ ignore/ignore.cp314-win_arm64.pyd,sha256=z02czUTbuyIQeWZRvYbm8I4OgKxcJLb6PUmpHyx5NJs,1505280
4
+ ignore/overrides/__init__.pyi,sha256=xY_thTelLGeBHnUmYLVM8IQi2C0YyQ7ddouNYcHSYuI,228
5
+ ignore/overrides/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
+ ignore/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
+ ignore_python-0.3.3.dist-info/METADATA,sha256=FmNJjYPgq14-KNtGCuggPvSk1TFYEipKmXAL1ifGBaU,2323
8
+ ignore_python-0.3.3.dist-info/WHEEL,sha256=Zz6cXSB5AOh1fgpVg-wWbmqD-E9bxFJou_OSuK1DxmA,97
9
+ ignore_python-0.3.3.dist-info/licenses/LICENSE.txt,sha256=tyonhx9LRyUnlYlQo-Vrp1EGS8gf6FEfA6xh9jZWPTk,1094
10
+ ignore_python-0.3.3.dist-info/sboms/ignore-python.cyclonedx.json,sha256=8lkEiJBMaaUdB43ljMFQIvdHG55u2OX6sm-ZGMPv5T8,37987
11
+ ignore_python-0.3.3.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: maturin (1.12.6)
3
+ Root-Is-Purelib: false
4
+ Tag: cp314-cp314-win_arm64
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Stefano Borsatto
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.