fs-tool-cli 0.1.2__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 (101) hide show
  1. fs_tool_cli-0.1.2/.agents/skills/filesystem-organizer/SKILL.md +65 -0
  2. fs_tool_cli-0.1.2/.github/FUNDING.yml +12 -0
  3. fs_tool_cli-0.1.2/.github/ISSUE_TEMPLATE/bug_report.md +31 -0
  4. fs_tool_cli-0.1.2/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
  5. fs_tool_cli-0.1.2/.github/PULL_REQUEST_TEMPLATE.md +15 -0
  6. fs_tool_cli-0.1.2/.github/actions/setup-environment/action.yml +15 -0
  7. fs_tool_cli-0.1.2/.github/dependabot.yml +6 -0
  8. fs_tool_cli-0.1.2/.github/workflows/main.yml +53 -0
  9. fs_tool_cli-0.1.2/.github/workflows/release.yml +48 -0
  10. fs_tool_cli-0.1.2/.github/workflows/update_readme.yml +38 -0
  11. fs_tool_cli-0.1.2/.gitignore +203 -0
  12. fs_tool_cli-0.1.2/.pre-commit-config-linux.yaml +15 -0
  13. fs_tool_cli-0.1.2/.pre-commit-config.yaml +13 -0
  14. fs_tool_cli-0.1.2/.readthedocs.yaml +20 -0
  15. fs_tool_cli-0.1.2/AGENTS.md +93 -0
  16. fs_tool_cli-0.1.2/LICENSE +24 -0
  17. fs_tool_cli-0.1.2/Makefile +117 -0
  18. fs_tool_cli-0.1.2/PKG-INFO +91 -0
  19. fs_tool_cli-0.1.2/README.md +79 -0
  20. fs_tool_cli-0.1.2/SECURITY.md +31 -0
  21. fs_tool_cli-0.1.2/docs/.nav.yml +15 -0
  22. fs_tool_cli-0.1.2/docs/_static/img/favicon.png +0 -0
  23. fs_tool_cli-0.1.2/docs/_static/img/logo.png +0 -0
  24. fs_tool_cli-0.1.2/docs/css/custom.css +5 -0
  25. fs_tool_cli-0.1.2/docs/develop/contributing.md +142 -0
  26. fs_tool_cli-0.1.2/docs/develop/naming_convention.md +46 -0
  27. fs_tool_cli-0.1.2/docs/funding/funding.md +55 -0
  28. fs_tool_cli-0.1.2/docs/getting-started/install.md +45 -0
  29. fs_tool_cli-0.1.2/docs/getting-started/virtual-environment.md +29 -0
  30. fs_tool_cli-0.1.2/docs/index.md +77 -0
  31. fs_tool_cli-0.1.2/docs/usage/cli.md +13 -0
  32. fs_tool_cli-0.1.2/mkdocs.yml +33 -0
  33. fs_tool_cli-0.1.2/plan.md +1123 -0
  34. fs_tool_cli-0.1.2/pyproject.toml +145 -0
  35. fs_tool_cli-0.1.2/pytest.ini +3 -0
  36. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Auslandssemester.docx +0 -0
  37. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Barcelona Sehenswertes.docx +0 -0
  38. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Beruf/Bewerbungen.txt +0 -0
  39. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Der Goldschatz partygame.pdf +0 -0
  40. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Ablauf Freitag Grundschule.docx +0 -0
  41. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Dresdner Christstollen.pdf +0 -0
  42. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Kirschkuchen.pdf +0 -0
  43. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Pelmeni.odt +0 -0
  44. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Projekte/Sauna_Grundriss.odg +0 -0
  45. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Seemeilenbestaetigung.pdf +0 -0
  46. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Freizeit/Tidal Prediction Form.pdf +0 -0
  47. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Reise/Segeln/Dalmatien 2018/2017-08-26_19-18_Sat.gpx +559 -0
  48. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Reise/Segeln/Segeln Ibiza 2024.gpx +41 -0
  49. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Reise/Slowenien/Klettersteige Slowenien.gpx +6602 -0
  50. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Reise-Checkliste.odt +0 -0
  51. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Sauna_Aufriss.odg +0 -0
  52. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Schule/Antrag Sch/303/274lerausweis.docx +0 -0
  53. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Studium/Oberseminare 2009 Helduser.pdf +0 -0
  54. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Tokensystem Z/303/244hneputzen.odt +0 -0
  55. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Urlaub/Der Weg zum SHS.ods +0 -0
  56. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Urlaub/Italien/Klettersteige Italien 2024.kmz +0 -0
  57. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Urlaub/Radtouren/Gittersee-steinbach.gpx +1250 -0
  58. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Urlaub/Radtouren/SingletrailDresdenerHeide.gpx +3087 -0
  59. fs_tool_cli-0.1.2/res/example_filesystem_unstructured/Urlaub/Radtouren/StauseeInDerDresdnerHeide.gpx +1466 -0
  60. fs_tool_cli-0.1.2/scripts/show_filelist.py +51 -0
  61. fs_tool_cli-0.1.2/scripts/show_tree.py +625 -0
  62. fs_tool_cli-0.1.2/scripts/update_readme.py +21 -0
  63. fs_tool_cli-0.1.2/setup.cfg +4 -0
  64. fs_tool_cli-0.1.2/src/fs_tool/__init__.py +9 -0
  65. fs_tool_cli-0.1.2/src/fs_tool/__main__.py +8 -0
  66. fs_tool_cli-0.1.2/src/fs_tool/cli.py +305 -0
  67. fs_tool_cli-0.1.2/src/fs_tool/core/__init__.py +1 -0
  68. fs_tool_cli-0.1.2/src/fs_tool/core/config.py +117 -0
  69. fs_tool_cli-0.1.2/src/fs_tool/core/errors.py +88 -0
  70. fs_tool_cli-0.1.2/src/fs_tool/core/filesystem.py +50 -0
  71. fs_tool_cli-0.1.2/src/fs_tool/core/hashing.py +49 -0
  72. fs_tool_cli-0.1.2/src/fs_tool/core/models.py +44 -0
  73. fs_tool_cli-0.1.2/src/fs_tool/core/py.typed +0 -0
  74. fs_tool_cli-0.1.2/src/fs_tool/core/traversal.py +225 -0
  75. fs_tool_cli-0.1.2/src/fs_tool/output/__init__.py +1 -0
  76. fs_tool_cli-0.1.2/src/fs_tool/output/json.py +142 -0
  77. fs_tool_cli-0.1.2/src/fs_tool/output/plain.py +58 -0
  78. fs_tool_cli-0.1.2/src/fs_tool/output/py.typed +0 -0
  79. fs_tool_cli-0.1.2/src/fs_tool/py.typed +0 -0
  80. fs_tool_cli-0.1.2/src/fs_tool/safety/__init__.py +1 -0
  81. fs_tool_cli-0.1.2/src/fs_tool/safety/py.typed +0 -0
  82. fs_tool_cli-0.1.2/src/fs_tool/safety/validation.py +81 -0
  83. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/PKG-INFO +91 -0
  84. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/SOURCES.txt +99 -0
  85. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/dependency_links.txt +1 -0
  86. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/entry_points.txt +2 -0
  87. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/requires.txt +5 -0
  88. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/scm_file_list.json +95 -0
  89. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/scm_version.json +8 -0
  90. fs_tool_cli-0.1.2/src/fs_tool_cli.egg-info/top_level.txt +1 -0
  91. fs_tool_cli-0.1.2/tasklist.md +321 -0
  92. fs_tool_cli-0.1.2/tests/conftest.py +28 -0
  93. fs_tool_cli-0.1.2/tests/test_cli.py +84 -0
  94. fs_tool_cli-0.1.2/tests/test_config.py +110 -0
  95. fs_tool_cli-0.1.2/tests/test_hashing.py +74 -0
  96. fs_tool_cli-0.1.2/tests/test_output.py +117 -0
  97. fs_tool_cli-0.1.2/tests/test_safety.py +120 -0
  98. fs_tool_cli-0.1.2/tests/test_traversal.py +196 -0
  99. fs_tool_cli-0.1.2/tests/test_tree.py +179 -0
  100. fs_tool_cli-0.1.2/uv.lock +817 -0
  101. fs_tool_cli-0.1.2/workflow.md +88 -0
@@ -0,0 +1,65 @@
1
+ # Filesystem Organization Skill
2
+
3
+ DRAFT! DO NOT USE YET!
4
+
5
+ ## Purpose
6
+
7
+ Use `fs-tool` to analyze, plan and safely reorganize local filesystems.
8
+
9
+ The agent is responsible for understanding the data and making organizational decisions. `fs-tool` is responsible for executing controlled filesystem operations.
10
+
11
+ ## General Workflow
12
+
13
+ ### 1. Understand
14
+
15
+ - Identify the target directory and accessible filesystem roots.
16
+ - Inspect the existing directory structure.
17
+ - Generate an inventory where appropriate.
18
+ - Examine file metadata, types, sizes and timestamps.
19
+ - Inspect file contents selectively when necessary.
20
+ - Identify duplicates, inconsistencies and poorly named files.
21
+
22
+ ### 2. Analyze
23
+
24
+ - Understand the apparent purpose and relationships of files.
25
+ - Identify logical groups and organizational opportunities.
26
+ - Distinguish confirmed information from assumptions.
27
+ - Avoid moving files based on filenames alone when relevant metadata is available.
28
+
29
+ ### 3. Plan
30
+
31
+ - Propose a consistent target directory structure.
32
+ - Map existing files and directories to their intended destinations.
33
+ - Identify renaming requirements and potential conflicts.
34
+ - Preserve existing information and avoid unnecessary changes.
35
+ - Present the proposed changes before execution.
36
+
37
+ ### 4. Validate
38
+
39
+ - Check all source and destination paths.
40
+ - Identify naming conflicts and duplicate content.
41
+ - Verify that the proposed operations are supported.
42
+ - Generate and inspect a dry-run before execution.
43
+
44
+ ### 5. Execute
45
+
46
+ - Use `fs-tool` for filesystem modifications.
47
+ - Obtain the required authorization for write and rename operations.
48
+ - Never overwrite or delete data without explicit authorization.
49
+ - Execute operations in manageable batches.
50
+ - Record relevant operation results.
51
+
52
+ ### 6. Verify
53
+
54
+ - Compare the resulting filesystem with the intended target structure.
55
+ - Verify copied or moved files using hashes where appropriate.
56
+ - Identify missing, unexpected or changed files.
57
+ - Report incomplete operations and unresolved conflicts.
58
+
59
+ ## Guiding Principles
60
+
61
+ - Preserve data integrity above all else.
62
+ - Prefer understandable structures over unnecessary complexity.
63
+ - Never guess when information can be inspected.
64
+ - Keep the user informed about significant decisions.
65
+ - Make all modifications traceable and verifiable.
@@ -0,0 +1,12 @@
1
+ # These are supported funding model platforms
2
+
3
+ github: [pamagister]
4
+ patreon: # Replace with a single Patreon username
5
+ open_collective: # Replace with a single Open Collective username
6
+ ko_fi: # Replace with a single Ko-fi username
7
+ tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8
+ community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9
+ liberapay: # Replace with a single Liberapay username
10
+ issuehunt: # Replace with a single IssueHunt username
11
+ otechie: # Replace with a single Otechie username
12
+ custom: ["https://www.paypal.me/PaulDD"]
@@ -0,0 +1,31 @@
1
+ ---
2
+ name: Bug report
3
+ about: Create a report to help us improve
4
+ title: ''
5
+ labels: bug, help wanted
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ **Describe the bug**
11
+ A clear and concise description of what the bug is.
12
+
13
+ **To Reproduce**
14
+ Steps to reproduce the behavior:
15
+ 1. Go to '...'
16
+ 2. Click on '....'
17
+ 3. Scroll down to '....'
18
+ 4. See error
19
+
20
+ **Expected behavior**
21
+ A clear and concise description of what you expected to happen.
22
+
23
+ **Screenshots**
24
+ If applicable, add screenshots to help explain your problem.
25
+
26
+ **Desktop (please complete the following information):**
27
+ - OS: [e.g. iOS]
28
+ - Version [e.g. 22]
29
+
30
+ **Additional context**
31
+ Add any other context about the problem here.
@@ -0,0 +1,20 @@
1
+ ---
2
+ name: Feature request
3
+ about: Suggest an idea for this project
4
+ title: ''
5
+ labels: enhancement, question
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ **Is your feature request related to a problem? Please describe.**
11
+ A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12
+
13
+ **Describe the solution you'd like**
14
+ A clear and concise description of what you want to happen.
15
+
16
+ **Describe alternatives you've considered**
17
+ A clear and concise description of any alternative solutions or features you've considered.
18
+
19
+ **Additional context**
20
+ Add any other context or screenshots about the feature request here.
@@ -0,0 +1,15 @@
1
+ ### Summary :memo:
2
+ _Write an overview about it._
3
+
4
+ ### Details
5
+ _Describe more what you did on changes._
6
+ 1. (...)
7
+ 2. (...)
8
+
9
+ ### Bugfixes :bug: (delete if dind't have any)
10
+ -
11
+
12
+ ### Checks
13
+ - [ ] Closed #798
14
+ - [ ] Tested Changes
15
+ - [ ] Stakeholder Approval
@@ -0,0 +1,15 @@
1
+ name: Setup Environment
2
+
3
+ description: Setup uv environment
4
+
5
+ runs:
6
+ using: "composite"
7
+ steps:
8
+ - name: Install uv
9
+ uses: astral-sh/setup-uv@v3
10
+ with:
11
+ version: "latest"
12
+
13
+ - name: Sync dependencies
14
+ run: uv sync --all-groups
15
+ shell: bash
@@ -0,0 +1,6 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "github-actions"
4
+ directory: "/"
5
+ schedule:
6
+ interval: "weekly"
@@ -0,0 +1,53 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+ workflow_dispatch:
9
+
10
+ concurrency:
11
+ group: ${{ github.workflow }}-${{ github.ref }}
12
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
13
+
14
+ jobs:
15
+ test:
16
+ strategy:
17
+ fail-fast: false
18
+ matrix:
19
+ python-version: ["3.11"]
20
+ os: [ubuntu-latest, macos-latest, windows-latest]
21
+ runs-on: ${{ matrix.os }}
22
+ steps:
23
+ - uses: actions/checkout@v7
24
+ - uses: actions/setup-python@v6
25
+ with:
26
+ python-version: ${{ matrix.python-version }}
27
+ - name: Setup environment
28
+ uses: ./.github/actions/setup-environment
29
+ - name: Run checks
30
+ if: runner.os != 'Windows'
31
+ run: make check
32
+ - name: Run Windows checks
33
+ if: runner.os == 'Windows'
34
+ shell: bash
35
+ run: |
36
+ uv run ruff check src/ tests/
37
+ uv run ruff format --check src/ tests/
38
+ uv run mypy src/
39
+ uv run pytest -v --cov=fs_tool -l --tb=short --maxfail=1 tests/
40
+ uv run coverage xml
41
+
42
+ build:
43
+ needs: test
44
+ runs-on: ubuntu-latest
45
+ steps:
46
+ - uses: actions/checkout@v7
47
+ - uses: actions/setup-python@v6
48
+ with:
49
+ python-version: "3.11"
50
+ - name: Setup environment
51
+ uses: ./.github/actions/setup-environment
52
+ - name: Build Python distributions
53
+ run: make build
@@ -0,0 +1,48 @@
1
+ name: Upload Python Package
2
+ permissions:
3
+ contents: write
4
+
5
+ on:
6
+ push:
7
+ tags:
8
+ - "*"
9
+
10
+ concurrency:
11
+ group: ${{ github.workflow }}-${{ github.ref }}
12
+ cancel-in-progress: false
13
+
14
+ jobs:
15
+ release:
16
+ name: Create Release
17
+ runs-on: ubuntu-latest
18
+ permissions:
19
+ contents: write
20
+ steps:
21
+ - uses: actions/checkout@v7
22
+ with:
23
+ fetch-depth: 0
24
+ - name: Release
25
+ uses: softprops/action-gh-release@v2
26
+ with:
27
+ generate_release_notes: true
28
+
29
+ deploy:
30
+ needs: release
31
+ runs-on: ubuntu-latest
32
+ permissions:
33
+ contents: read
34
+ id-token: write
35
+ steps:
36
+ - uses: actions/checkout@v7
37
+ with:
38
+ fetch-depth: 0
39
+ - name: Set up Python
40
+ uses: actions/setup-python@v6
41
+ with:
42
+ python-version: "3.11"
43
+ - name: Install build tools
44
+ run: python -m pip install --upgrade build
45
+ - name: Build distributions
46
+ run: python -m build
47
+ - name: Publish to PyPI
48
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,38 @@
1
+ name: Sync README with docs/index.md
2
+
3
+ permissions:
4
+ contents: write
5
+
6
+ on:
7
+ push:
8
+ paths:
9
+ - "docs/index.md"
10
+ branches: [main]
11
+ workflow_dispatch:
12
+
13
+ concurrency:
14
+ group: ${{ github.workflow }}-${{ github.ref }}
15
+ cancel-in-progress: false
16
+
17
+ jobs:
18
+ sync:
19
+ runs-on: ubuntu-latest
20
+ steps:
21
+ - uses: actions/checkout@v7
22
+ - name: Set up Python
23
+ uses: actions/setup-python@v7
24
+ with:
25
+ python-version: "3.11"
26
+ - name: Update README.md
27
+ run: python scripts/update_readme.py
28
+ - name: Commit changes
29
+ run: |
30
+ git config user.name "github-actions"
31
+ git config user.email "github-actions@github.com"
32
+ git add README.md
33
+ if git diff --cached --quiet; then
34
+ echo "README.md is already in sync."
35
+ exit 0
36
+ fi
37
+ git commit -m "docs: sync README from docs/index.md"
38
+ git push origin "HEAD:${GITHUB_REF_NAME}"
@@ -0,0 +1,203 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ # Usually these files are written by a python script from a template
31
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
32
+ *.manifest
33
+ *.spec
34
+
35
+ # Installer logs
36
+ pip-log.txt
37
+ pip-delete-this-directory.txt
38
+
39
+ # Unit test / coverage reports
40
+ htmlcov/
41
+ .tox/
42
+ .nox/
43
+ .coverage
44
+ .coverage.*
45
+ .cache
46
+ nosetests.xml
47
+ coverage.xml
48
+ *.cover
49
+ *.py,cover
50
+ .hypothesis/
51
+ .pytest_cache/
52
+ cover/
53
+
54
+ # Translations
55
+ *.mo
56
+ *.pot
57
+
58
+ # Django stuff:
59
+ *.log
60
+ local_settings.py
61
+ db.sqlite3
62
+ db.sqlite3-journal
63
+
64
+ # Flask stuff:
65
+ instance/
66
+ .webassets-cache
67
+
68
+ # Scrapy stuff:
69
+ .scrapy
70
+
71
+ # Sphinx documentation
72
+ docs/_build/
73
+
74
+ # PyBuilder
75
+ .pybuilder/
76
+ target/
77
+
78
+ # Jupyter Notebook
79
+ .ipynb_checkpoints
80
+
81
+ # IPython
82
+ profile_default/
83
+ ipython_config.py
84
+
85
+ # pyenv
86
+ # For a library or package, you might want to ignore these files since the code is
87
+ # intended to run in multiple environments; otherwise, check them in:
88
+ # .python-version
89
+
90
+ # pipenv
91
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
92
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
93
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
94
+ # install all needed dependencies.
95
+ #Pipfile.lock
96
+
97
+ # UV
98
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
99
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
100
+ # commonly ignored for libraries.
101
+ #uv.lock
102
+
103
+ # poetry
104
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
105
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
106
+ # commonly ignored for libraries.
107
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
108
+ #poetry.lock
109
+
110
+ # pdm
111
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
112
+ #pdm.lock
113
+ # pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
114
+ # in version control.
115
+ # https://pdm.fming.dev/latest/usage/project/#working-with-version-control
116
+ .pdm.toml
117
+ .pdm-python
118
+ .pdm-build/
119
+
120
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
121
+ __pypackages__/
122
+
123
+ # Celery stuff
124
+ celerybeat-schedule
125
+ celerybeat.pid
126
+
127
+ # SageMath parsed files
128
+ *.sage.py
129
+
130
+ # Environments
131
+ .env
132
+ .venv
133
+ env/
134
+ venv/
135
+ ENV/
136
+ env.bak/
137
+ venv.bak/
138
+
139
+ # Spyder project settings
140
+ .spyderproject
141
+ .spyproject
142
+
143
+ # Rope project settings
144
+ .ropeproject
145
+
146
+ # mkdocs documentation
147
+ /site
148
+
149
+ # mypy
150
+ .mypy_cache/
151
+ .dmypy.json
152
+ dmypy.json
153
+
154
+ # Pyre type checker
155
+ .pyre/
156
+
157
+ # pytype static type analyzer
158
+ .pytype/
159
+
160
+ # Cython debug symbols
161
+ cython_debug/
162
+
163
+ # PyCharm
164
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
165
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
166
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
167
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
168
+ #.idea/
169
+
170
+ # Abstra
171
+ # Abstra is an AI-powered process automation framework.
172
+ # Ignore directories containing user credentials, local state, and settings.
173
+ # Learn more at https://abstra.io/docs
174
+ .abstra/
175
+
176
+ # Visual Studio Code
177
+ # Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
178
+ # that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
179
+ # and can be added to the global gitignore or merged into this file. However, if you prefer,
180
+ # you could uncomment the following to ignore the enitre vscode folder
181
+ # .vscode/
182
+
183
+ # Ruff stuff:
184
+ .ruff_cache/
185
+
186
+ # PyPI configuration file
187
+ .pypirc
188
+
189
+ # Cursor
190
+ # Cursor is an AI-powered code editor. `.cursorignore` specifies files/directories to
191
+ # exclude from AI features like autocomplete and code analysis. Recommended for sensitive data
192
+ # refer to https://docs.cursor.com/context/ignore-files
193
+ .cursorignore
194
+ .cursorindexingignore
195
+ /.idea/misc.xml
196
+ /.idea/modules.xml
197
+ /.idea/fs-tool.iml
198
+ /.idea/inspectionProfiles/profiles_settings.xml
199
+ /.idea/inspectionProfiles/Project_Default.xml
200
+ /src/fs_tool/_version.py
201
+ /release/config.yaml
202
+ /release/fs-tool.exe
203
+ /release/README.md
@@ -0,0 +1,15 @@
1
+ # the actual pre-commit is defined in the Makefile
2
+ # install and activate pre-commit:
3
+ # > pre-commit install
4
+ #
5
+ # on Linux, rename this file to .pre-commit-config.yaml and use this one
6
+
7
+ repos:
8
+ - repo: local
9
+ hooks:
10
+ - id: run-make-precommit
11
+ name: Run `make precommit`
12
+ entry: bash -c "export PATH=$HOME/.local/bin:$PATH && uv run make precommit"
13
+ language: system
14
+ always_run: true
15
+ pass_filenames: false
@@ -0,0 +1,13 @@
1
+ # the actual pre-commit is defined in the Makefile
2
+ # install and activate pre-commit:
3
+ # > pre-commit install
4
+
5
+ repos:
6
+ - repo: local
7
+ hooks:
8
+ - id: run-make-precommit
9
+ name: Run `make precommit`
10
+ entry: make precommit
11
+ language: system
12
+ always_run: true
13
+ pass_filenames: false
@@ -0,0 +1,20 @@
1
+ # .readthedocs.yaml
2
+ # Read the Docs configuration file
3
+ # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
4
+
5
+ version: 2
6
+
7
+ build:
8
+ os: ubuntu-22.04
9
+ tools:
10
+ python: "3.11"
11
+
12
+ python:
13
+ install:
14
+ - method: uv
15
+ command: sync
16
+ groups:
17
+ - docs
18
+
19
+ mkdocs:
20
+ configuration: mkdocs.yml
@@ -0,0 +1,93 @@
1
+ # AGENTS.md
2
+
3
+ ## Principles
4
+
5
+ - Understand the task; inspect relevant code, configuration, tests, and conventions.
6
+ - Clarify material ambiguity or state assumptions. Make the smallest correct change, following
7
+ established patterns and avoiding unrelated refactors, speculative features, and unnecessary
8
+ dependencies.
9
+ - Keep code clear and maintainable; preserve type safety and compatibility. Surface errors with
10
+ useful context; avoid broad catches and silent failures.
11
+ - Use english language in doc strings, documentation and comments.
12
+
13
+ ## Python
14
+
15
+ - Follow PEP 8 and the project's formatter and configuration.
16
+ - Use descriptive names, type-hint function signatures, and document public APIs. Avoid `Any`
17
+ unless necessary.
18
+ - Keep functions focused; use dataclasses for simple data containers when appropriate. Avoid
19
+ mutable defaults, and use `is` for `None`, `True`, and `False`.
20
+ - Prefer explicit imports, f-strings, and context managers.
21
+ - Avoid wildcard imports and redundant comments.
22
+
23
+
24
+ ## Workflow
25
+
26
+ 1. **Inspect** the relevant code, project structure, configuration, dependencies, and existing tests before making changes.
27
+ 2. **Plan** briefly for nontrivial tasks. Define concrete, verifiable success criteria.
28
+ 3. **Implement** the smallest complete solution, following existing project conventions.
29
+ 4. **Verify** changes with relevant tests, formatting, linting, and type checking. Fix issues introduced by the changes.
30
+ 5. **Report** what changed, which checks passed, and any remaining limitations.
31
+
32
+ Do not claim that checks passed unless they were actually executed. If verification is impossible, explain why.
33
+
34
+ ## Tests
35
+
36
+ - Add or update "Tests with Teeth" for behavior changes and important edge/failure cases. Keep tests
37
+ deterministic, mock only when needed, and never weaken tests to pass.
38
+ - Run relevant configured checks and report what actually ran; do not claim unrun checks passed.
39
+
40
+ ## Dependencies and Tooling
41
+
42
+ - Use `uv` for dependency management and virtual environments when available or when initializing a project.
43
+ - Declare and manage dependencies in `pyproject.toml`. Avoid unnecessary dependencies and preserve existing project tooling.
44
+ - Prefer established project commands and configuration over introducing new tools or conventions.
45
+ - Use `ruff` for formatting and linting and `mypy` for static type checking when configured or appropriate.
46
+ - Use `pytest` for tests. Add or update tests for new behavior, bug fixes, and meaningful edge cases. Mock external dependencies where appropriate.
47
+ - Never introduce tooling or dependencies solely for marginal benefits.
48
+
49
+ ## Project workflows and generated files
50
+
51
+ - Use existing Makefile targets when relevant; common checks are
52
+
53
+ ```bash
54
+ make fmt
55
+ make lint
56
+ make test
57
+ ```
58
+
59
+ Check the Makefile and project configuration rather than assuming a command exists.
60
+ - `make syncdocs` runs `scripts/generate_config_docs.py`, `scripts/update_readme.py`, and
61
+ `.github/update_funding.py`. It regenerates `config.yaml`, `docs/usage/config.md`,
62
+ `docs/usage/cli.md`, `README.md`, and `docs/funding/funding.md`. Do not edit these outputs
63
+ directly: update the relevant `ConfigCategory` definitions used by `ConfigManager` or
64
+ `docs/index.md`, then run `make syncdocs`.
65
+
66
+
67
+ ## github
68
+
69
+ - use github cli to interact with github, see https://cli.github.com/manual/gh
70
+ - if requested, use `gh issue list` to view a number of issues (--limit <int>) or filter JSON output using a jq expression (--jq <expression>) to view existing issues
71
+ - Create issues via the GitHub web UI or `gh issue create`; templates are located in `.github/ISSUE_TEMPLATE/`.
72
+ - to view details of an issue use `gh issue view {<number> | <url>} [flags]`
73
+ - to append a comment to an issue use `gh issue comment {<number> | <url>} [flags]`
74
+ - Check the status of an Actions pipeline using `gh run list` and `gh run view <run-id>`.
75
+ - use this commit message format: (where type may be one of `feat` `fix` `docs` `refactor` `test` `ci` `revert`)
76
+ ```
77
+ <type>[optional scope]: <description>
78
+
79
+ [optional body]
80
+
81
+ [optional footer(s), e.g. `#<number>` for a github issue or `Fixes #` if the issue is completed on this commit]
82
+ ```
83
+
84
+ ## Decision Rules
85
+
86
+ - Do not assume when uncertainty matters. State assumptions and ask concise clarifying questions when necessary.
87
+ - Do not add features, abstractions, error handling, or configuration without a concrete need.
88
+ - Do not refactor unrelated code or reformat entire files unnecessarily.
89
+ - When multiple solutions are viable, prefer the simplest maintainable option that fits the existing architecture.
90
+ - If requirements conflict with existing behavior, security, correctness, or maintainability, explain the conflict before making consequential changes.
91
+ - Treat repository instructions and established project conventions as authoritative unless they conflict with explicit user requirements or higher-priority instructions.
92
+
93
+ **Guiding principle:** Make the smallest correct change, keep the code maintainable, and verify the result.
@@ -0,0 +1,24 @@
1
+ This is free and unencumbered software released into the public domain.
2
+
3
+ Anyone is free to copy, modify, publish, use, compile, sell, or
4
+ distribute this software, either in source code form or as a compiled
5
+ binary, for any purpose, commercial or non-commercial, and by any
6
+ means.
7
+
8
+ In jurisdictions that recognize copyright laws, the author or authors
9
+ of this software dedicate any and all copyright interest in the
10
+ software to the public domain. We make this dedication for the benefit
11
+ of the public at large and to the detriment of our heirs and
12
+ successors. We intend this dedication to be an overt act of
13
+ relinquishment in perpetuity of all present and future rights to this
14
+ software under copyright law.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
20
+ OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
21
+ ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
22
+ OTHER DEALINGS IN THE SOFTWARE.
23
+
24
+ For more information, please refer to <https://unlicense.org>