kanban-python 0.4.0__tar.gz → 0.5.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 (63) hide show
  1. kanban_python-0.5.1/.github/workflows/ci.yml +101 -0
  2. {kanban-python-0.4.0 → kanban_python-0.5.1}/.gitignore +0 -1
  3. kanban_python-0.5.1/.pre-commit-config.yaml +30 -0
  4. kanban_python-0.5.1/.python-version +1 -0
  5. {kanban-python-0.4.0 → kanban_python-0.5.1}/CHANGELOG.md +17 -0
  6. {kanban-python-0.4.0 → kanban_python-0.5.1}/PKG-INFO +63 -31
  7. kanban-python-0.4.0/src/kanban_python.egg-info/PKG-INFO → kanban_python-0.5.1/README.md +23 -35
  8. kanban_python-0.5.1/pyproject.toml +55 -0
  9. kanban_python-0.5.1/src/kanban_python/app.py +69 -0
  10. kanban_python-0.5.1/src/kanban_python/cli_parser.py +63 -0
  11. {kanban-python-0.4.0 → kanban_python-0.5.1}/src/kanban_python/config.py +3 -1
  12. {kanban-python-0.4.0 → kanban_python-0.5.1}/src/kanban_python/controls.py +35 -27
  13. {kanban-python-0.4.0 → kanban_python-0.5.1}/src/kanban_python/interface.py +2 -1
  14. {kanban-python-0.4.0 → kanban_python-0.5.1}/src/kanban_python/utils.py +10 -7
  15. {kanban-python-0.4.0 → kanban_python-0.5.1}/tests/test_config.py +7 -2
  16. kanban_python-0.5.1/uv.lock +395 -0
  17. kanban-python-0.4.0/.github/workflows/ci.yml +0 -127
  18. kanban-python-0.4.0/.isort.cfg +0 -3
  19. kanban-python-0.4.0/.pre-commit-config.yaml +0 -67
  20. kanban-python-0.4.0/.readthedocs.yml +0 -27
  21. kanban-python-0.4.0/CONTRIBUTING.md +0 -371
  22. kanban-python-0.4.0/README.md +0 -198
  23. kanban-python-0.4.0/docs/Makefile +0 -29
  24. kanban-python-0.4.0/docs/_static/.gitignore +0 -1
  25. kanban-python-0.4.0/docs/authors.md +0 -4
  26. kanban-python-0.4.0/docs/changelog.md +0 -4
  27. kanban-python-0.4.0/docs/conf.py +0 -304
  28. kanban-python-0.4.0/docs/contributing.md +0 -4
  29. kanban-python-0.4.0/docs/index.md +0 -39
  30. kanban-python-0.4.0/docs/license.md +0 -5
  31. kanban-python-0.4.0/docs/readme.md +0 -4
  32. kanban-python-0.4.0/docs/requirements.txt +0 -6
  33. kanban-python-0.4.0/pyproject.toml +0 -9
  34. kanban-python-0.4.0/setup.cfg +0 -81
  35. kanban-python-0.4.0/setup.py +0 -21
  36. kanban-python-0.4.0/src/kanban_python/app.py +0 -133
  37. kanban-python-0.4.0/src/kanban_python/cli_parser.py +0 -62
  38. kanban-python-0.4.0/src/kanban_python.egg-info/SOURCES.txt +0 -55
  39. kanban-python-0.4.0/src/kanban_python.egg-info/dependency_links.txt +0 -1
  40. kanban-python-0.4.0/src/kanban_python.egg-info/entry_points.txt +0 -2
  41. kanban-python-0.4.0/src/kanban_python.egg-info/not-zip-safe +0 -1
  42. kanban-python-0.4.0/src/kanban_python.egg-info/requires.txt +0 -11
  43. kanban-python-0.4.0/src/kanban_python.egg-info/top_level.txt +0 -1
  44. kanban-python-0.4.0/tox.ini +0 -93
  45. {kanban-python-0.4.0 → kanban_python-0.5.1}/.coveragerc +0 -0
  46. {kanban-python-0.4.0 → kanban_python-0.5.1}/AUTHORS.md +0 -0
  47. {kanban-python-0.4.0 → kanban_python-0.5.1}/LICENSE.txt +0 -0
  48. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_config.PNG +0 -0
  49. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_header.PNG +0 -0
  50. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_kanban.PNG +0 -0
  51. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_kanban_change.PNG +0 -0
  52. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_kanban_configure.PNG +0 -0
  53. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_kanban_init.PNG +0 -0
  54. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_kanban_report.PNG +0 -0
  55. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_kanban_report_document.PNG +0 -0
  56. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_scan_table.PNG +0 -0
  57. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_scan_view.PNG +0 -0
  58. {kanban-python-0.4.0 → kanban_python-0.5.1}/images/image_task_example.PNG +0 -0
  59. {kanban-python-0.4.0 → kanban_python-0.5.1}/src/kanban_python/__init__.py +0 -0
  60. {kanban-python-0.4.0 → kanban_python-0.5.1}/src/kanban_python/constants.py +0 -0
  61. {kanban-python-0.4.0 → kanban_python-0.5.1}/tests/conftest.py +0 -0
  62. {kanban-python-0.4.0 → kanban_python-0.5.1}/tests/test_interface.py +0 -0
  63. {kanban-python-0.4.0 → kanban_python-0.5.1}/tests/test_utils.py +0 -0
@@ -0,0 +1,101 @@
1
+ name: Continuous Integration
2
+
3
+ on:
4
+ push:
5
+ # Avoid using all the resources/limits available by checking only
6
+ # relevant branches and tags. Other branches can be checked via PRs.
7
+ # branches: [main]
8
+ tags: ['v[0-9]*', '[0-9]+.[0-9]+*'] # Match tags that resemble a version
9
+ pull_request: # Run in every PR
10
+ workflow_dispatch: # Allow manually triggering the workflow
11
+
12
+ permissions:
13
+ contents: read
14
+
15
+
16
+ jobs:
17
+ tests:
18
+ strategy:
19
+ matrix:
20
+ python-version:
21
+ - "3.9"
22
+ - "3.12"
23
+ platform:
24
+ - ubuntu-latest
25
+ - macos-latest
26
+ - windows-latest
27
+ runs-on: ${{matrix.platform}}
28
+
29
+ steps:
30
+ - uses: actions/checkout@v4
31
+
32
+ - name: Install uv
33
+ uses: astral-sh/setup-uv@v3
34
+ with:
35
+ enable-cache: true
36
+
37
+ - name: "Set up Python"
38
+ uses: actions/setup-python@v5
39
+ with:
40
+ python-version: ${{matrix.python-version}}
41
+ - name: Install the project
42
+ run: uv sync --all-extras --dev
43
+
44
+ - name: Run tests
45
+ # For example, using `pytest`
46
+ run: uv run pytest tests
47
+
48
+ # Generate Coverage
49
+ - name: Generate coverage report
50
+ run: uv run coverage lcov -o coverage.lcov
51
+ - name: Upload partial coverage report
52
+ uses: coverallsapp/github-action@v2
53
+ with:
54
+ path-to-lcov: coverage.lcov
55
+ github-token: ${{ secrets.GITHUB_TOKEN }}
56
+ flag-name: ${{ matrix.platform }} - py${{ matrix.python }}
57
+ parallel: true
58
+
59
+ finalize_coverage:
60
+ needs: tests
61
+ runs-on: ubuntu-latest
62
+ steps:
63
+ - name: Finalize coverage report
64
+ uses: coverallsapp/github-action@v2
65
+ with:
66
+ github-token: ${{ secrets.GITHUB_TOKEN }}
67
+ parallel-finished: true
68
+
69
+ publish:
70
+ needs: finalize_coverage
71
+ if: ${{ github.event_name == 'push' && contains(github.ref, 'refs/tags/') }}
72
+ runs-on: ubuntu-latest
73
+ environment: 'deploy'
74
+ permissions:
75
+ # IMPORTANT: this permission is mandatory for trusted publishing
76
+ # id-token: write
77
+ contents: write
78
+ steps:
79
+ - uses: actions/checkout@v4
80
+
81
+ - name: Install uv
82
+ uses: astral-sh/setup-uv@v3
83
+ with:
84
+ enable-cache: true
85
+
86
+ - name: "Set up Python"
87
+ uses: actions/setup-python@v5
88
+ with:
89
+ python-version-file: ".python-version"
90
+
91
+ - name: "Build Package"
92
+ run: uv build
93
+
94
+ - name: "Publish Package to PyPi"
95
+ env:
96
+ # UV_PUBLISH_USERNAME: __token__
97
+ UV_PUBLISH_TOKEN: ${{secrets.PYPI_TOKEN}}
98
+
99
+ run: uv publish
100
+ # - name: Publish package distributions to PyPI
101
+ # uses: pypa/gh-action-pypi-publish@release/v1
@@ -52,4 +52,3 @@ MANIFEST
52
52
  # Per-project virtualenvs
53
53
  .venv*/
54
54
  .conda*/
55
- .python-version
@@ -0,0 +1,30 @@
1
+ # See https://pre-commit.com for more information
2
+ # See https://pre-commit.com/hooks.html for more hooks
3
+ repos:
4
+ - repo: https://github.com/pre-commit/pre-commit-hooks
5
+ rev: v5.0.0
6
+ hooks:
7
+ - id: trailing-whitespace
8
+ - id: end-of-file-fixer
9
+ - id: check-yaml
10
+ - id: check-added-large-files
11
+ args: ["--maxkb=600"]
12
+
13
+
14
+ - repo: https://github.com/astral-sh/ruff-pre-commit
15
+ # Ruff version.
16
+ rev: v0.7.2
17
+ hooks:
18
+ # Run the linter.
19
+ - id: ruff
20
+ # Run the formatter.
21
+ - id: ruff-format
22
+
23
+ #- repo: local
24
+ # hooks:
25
+ # - id: run tests
26
+ # name: Run Tests
27
+ # language: system
28
+ # entry: pytest
29
+ # pass_filenames: false
30
+ # always_run: true
@@ -0,0 +1 @@
1
+ 3.12
@@ -1,5 +1,22 @@
1
1
  # Changelog
2
2
 
3
+ ## Version 0.5.1
4
+ - Fix deploymet issue caused by missing version file
5
+
6
+ ## Version 0.5.0
7
+ - Move Project to uv structure and cleanup repository gh-17
8
+ - improve argparser to support new funtionality and give better command overview
9
+ - add `-l`/`--local` flag to `kanban init` command as a shortcut to create a board named `local`, which creates a local board.
10
+ Local boards are stored in the current working directory and not under `user_data_dir`.
11
+ - add `path` argument to `kanban scan` command to declare which path to scan for tasks
12
+ - add `path` argument to `kanban report` command to declare path where the report should be created
13
+
14
+ ## Version 0.4.1
15
+ - Update minimum python version in ci test
16
+
17
+ ## Version 0.4.0
18
+ - Update Docs with pipx link
19
+
3
20
  ## Version 0.3.10
4
21
  - Fix datetime for test for dict creation
5
22
  - Amount of completed task to tasks of current year in report
@@ -1,26 +1,46 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.3
2
2
  Name: kanban-python
3
- Version: 0.4.0
3
+ Version: 0.5.1
4
4
  Summary: Terminal Kanban App written in Python
5
- Home-page: https://github.com/Zaloog/kanban-python
6
- Author: Zaloog
7
- Author-email: gramslars@gmail.com
8
- License: MIT
9
- Project-URL: Source, https://github.com/Zaloog/kanban-python
10
- Project-URL: Tracker, https://github.com/Zaloog/kanban-python/issues
11
- Platform: any
12
- Classifier: Development Status :: 4 - Beta
13
- Classifier: Programming Language :: Python
14
- Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
5
+ Project-URL: Repository, https://github.com/Zaloog/kanban-python
6
+ Project-URL: Changelog, https://github.com/Zaloog/kanban-python/blob/main/CHANGELOG.md
7
+ Author-email: Zaloog <gramslars@gmail.com>
8
+ License: The MIT License (MIT)
9
+
10
+ Copyright (c) 2023 Zaloog
11
+
12
+ Permission is hereby granted, free of charge, to any person obtaining a copy
13
+ of this software and associated documentation files (the "Software"), to deal
14
+ in the Software without restriction, including without limitation the rights
15
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
16
+ copies of the Software, and to permit persons to whom the Software is
17
+ furnished to do so, subject to the following conditions:
18
+
19
+ The above copyright notice and this permission notice shall be included in all
20
+ copies or substantial portions of the Software.
21
+
22
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
27
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
28
+ SOFTWARE.
29
+ License-File: AUTHORS.md
15
30
  License-File: LICENSE.txt
16
- Requires-Dist: importlib-metadata; python_version < "3.8"
17
- Requires-Dist: rich>=13.7.0
18
- Requires-Dist: platformdirs<4,>=3
19
- Provides-Extra: testing
20
- Requires-Dist: setuptools; extra == "testing"
21
- Requires-Dist: pytest; extra == "testing"
22
- Requires-Dist: freezegun; extra == "testing"
23
- Requires-Dist: pytest-cov; extra == "testing"
31
+ Classifier: Development Status :: 3 - Alpha
32
+ Classifier: License :: OSI Approved :: MIT License
33
+ Classifier: Operating System :: OS Independent
34
+ Classifier: Programming Language :: Python
35
+ Classifier: Programming Language :: Python :: 3 :: Only
36
+ Classifier: Programming Language :: Python :: 3.9
37
+ Classifier: Programming Language :: Python :: 3.10
38
+ Classifier: Programming Language :: Python :: 3.11
39
+ Classifier: Programming Language :: Python :: 3.12
40
+ Requires-Python: >=3.9
41
+ Requires-Dist: platformdirs>=4.3.6
42
+ Requires-Dist: rich>=13.9.4
43
+ Description-Content-Type: text/markdown
24
44
 
25
45
  <!-- These are examples of badges you might want to add to your README:
26
46
  please update the URLs accordingly
@@ -34,9 +54,12 @@ Requires-Dist: pytest-cov; extra == "testing"
34
54
  -->
35
55
 
36
56
  [![Project generated with PyScaffold](https://img.shields.io/badge/-PyScaffold-005CA0?logo=pyscaffold)](https://pyscaffold.org/)
57
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
37
58
  [![PyPI-Server](https://img.shields.io/pypi/v/kanban-python.svg)](https://pypi.org/project/kanban-python/)
59
+ [![Pyversions](https://img.shields.io/pypi/pyversions/kanban-tui.svg)](https://pypi.python.org/pypi/kanban-tui)
60
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
38
61
  [![Downloads](https://static.pepy.tech/badge/kanban-python)](https://pepy.tech/project/kanban-python)
39
- [![Coverage Status](https://coveralls.io/repos/github/Zaloog/kanban-python/badge.svg?branch=refs/tags/v0.3.10)](https://coveralls.io/github/Zaloog/kanban-python?branch=refs/tags/v0.3.10)
62
+ [![Coverage Status](https://coveralls.io/repos/github/Zaloog/kanban-python/badge.svg?branch=main)](https://coveralls.io/github/Zaloog/kanban-python?branch=main)
40
63
  # kanban-python
41
64
 
42
65
  > A Terminal Kanban Application written in Python to boost your productivity :rocket:
@@ -51,9 +74,10 @@ my own Terminal Kanban Application since I preferred a more simple and guided wo
51
74
  **kanban-python** also comes with more features, like custom column creation,
52
75
  automatic scanning and customizable config file to support you being productive.
53
76
 
54
- This package was developed with [pyscaffold], which provides awesome project templates
77
+ This package was initially developed with [pyscaffold], which provides awesome project templates
55
78
  and takes over much of the boilerplate for python packaging.
56
79
  It was a great help for developing my first package and I can highly recommend it.
80
+ With version `0.5.X` the repository structure was changed to use [uv].
57
81
 
58
82
  ## Features
59
83
  <details><summary>Colorful and Interactive</summary>
@@ -142,10 +166,13 @@ You can install kanban-python with:
142
166
  python -m pip install kanban-python
143
167
  ```
144
168
 
145
- or using [pipx]:
169
+ or using [pipx] / [uv] / [rye]:
146
170
  ```bash
147
- pipx install kanban-python
171
+ pipx install kanban-python # using pipx
172
+ uv tool install kanban-python # using uv
173
+ rye install kanban-python # using rye
148
174
  ```
175
+ I recommend using pipx, rye or uv to install CLI Tools into an isolated environment.
149
176
 
150
177
  ## Usage
151
178
  After Installation of kanban-python, there are 5 commands available:
@@ -158,6 +185,10 @@ Is used to create a new kanban board i.e. it asks for a name and then creates a
158
185
  On first use of any command, the `pykanban.ini` configfile and the `kanban-python` folder will be created automatically.
159
186
  ![init_file](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_kanban_init.PNG)
160
187
 
188
+ You can create local boards in the current working directory by using the name `local` or the flags `-l` or `--local` when
189
+ using `kanban init`. kanban-python checks for local boards and updates the config file accordingly.
190
+ Local boards can only be accessed when using `kanban` in the same folder.
191
+
161
192
  ### Interact with Tasks/Boards
162
193
  ```bash
163
194
  kanban
@@ -173,7 +204,7 @@ or changing settings, your progress wont be saved.
173
204
  ```bash
174
205
  kanban scan
175
206
  ```
176
- After executing this command, kanban-python scans your current Directory recursively for the defined filetypes and searches for lines
207
+ After executing this command, kanban-python scans your current directory recursively for the defined filetypes and searches for lines
177
208
  that start with the pattern provided.
178
209
  ![scan_view](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_scan_view.PNG)
179
210
 
@@ -181,6 +212,8 @@ After confirmation to add the found tasks to table they will be added to the boa
181
212
  The filepath were the task was found will be added as description of the task.
182
213
  ![scan_table](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_scan_table.PNG)
183
214
 
215
+ You can also define a different path to scan with the `-p` or `--path` argument.
216
+
184
217
  ### Create Report
185
218
  ```bash
186
219
  kanban report
@@ -189,13 +222,15 @@ Goes over all your Boards and creates a single markdown file by checking the `Co
189
222
  Also shows a nice github-like contribution table for the current year.
190
223
  ![report](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_kanban_report.PNG)
191
224
 
225
+ You can define a different output path of the `pykanban.md` report file with the `-p` or `--path` argument.
226
+
192
227
  ### Change Settings
193
228
  ```bash
194
229
  kanban configure
195
230
  ```
196
231
  ![settings](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_kanban_configure.PNG)
197
232
 
198
- To create a new custom Columns, you have to edit the `pykanban.ini` manually and add a new column name + visibility status
233
+ To create a new custom Column, you have to edit the `pykanban.ini` manually and add a new column name + visibility status
199
234
  under the `settings.columns.visible` section. The other options are all customizable now via the new settings menu.
200
235
 
201
236
 
@@ -207,12 +242,7 @@ Also check the [Changelog](https://github.com/Zaloog/kanban-python/blob/main/CHA
207
242
  With release v0.3.0 kanban-python switched to the [XDG] Basedir Spec. So some file migrations and config edits might be
208
243
  needed to continue working with your already created boards if you update from `v0.2.X` to `v0.3.X`
209
244
 
210
- <!-- pyscaffold-notes -->
211
-
212
- ## Note
213
245
 
214
- This project has been set up using PyScaffold 4.5. For details and usage
215
- information on PyScaffold see https://pyscaffold.org/.
216
246
 
217
247
  [XDG]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
218
248
  [platformdirs]: https://platformdirs.readthedocs.io/en/latest/
@@ -220,3 +250,5 @@ information on PyScaffold see https://pyscaffold.org/.
220
250
  [pyscaffold]: https://pyscaffold.org/
221
251
  [rich]: https://github.com/Textualize/rich
222
252
  [pipx]: https://github.com/pypa/pipx
253
+ [uv]: https://docs.astral.sh/uv/
254
+ [rye]: https://rye.astral.sh
@@ -1,27 +1,3 @@
1
- Metadata-Version: 2.1
2
- Name: kanban-python
3
- Version: 0.4.0
4
- Summary: Terminal Kanban App written in Python
5
- Home-page: https://github.com/Zaloog/kanban-python
6
- Author: Zaloog
7
- Author-email: gramslars@gmail.com
8
- License: MIT
9
- Project-URL: Source, https://github.com/Zaloog/kanban-python
10
- Project-URL: Tracker, https://github.com/Zaloog/kanban-python/issues
11
- Platform: any
12
- Classifier: Development Status :: 4 - Beta
13
- Classifier: Programming Language :: Python
14
- Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
15
- License-File: LICENSE.txt
16
- Requires-Dist: importlib-metadata; python_version < "3.8"
17
- Requires-Dist: rich>=13.7.0
18
- Requires-Dist: platformdirs<4,>=3
19
- Provides-Extra: testing
20
- Requires-Dist: setuptools; extra == "testing"
21
- Requires-Dist: pytest; extra == "testing"
22
- Requires-Dist: freezegun; extra == "testing"
23
- Requires-Dist: pytest-cov; extra == "testing"
24
-
25
1
  <!-- These are examples of badges you might want to add to your README:
26
2
  please update the URLs accordingly
27
3
 
@@ -34,9 +10,12 @@ Requires-Dist: pytest-cov; extra == "testing"
34
10
  -->
35
11
 
36
12
  [![Project generated with PyScaffold](https://img.shields.io/badge/-PyScaffold-005CA0?logo=pyscaffold)](https://pyscaffold.org/)
13
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
37
14
  [![PyPI-Server](https://img.shields.io/pypi/v/kanban-python.svg)](https://pypi.org/project/kanban-python/)
15
+ [![Pyversions](https://img.shields.io/pypi/pyversions/kanban-tui.svg)](https://pypi.python.org/pypi/kanban-tui)
16
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
38
17
  [![Downloads](https://static.pepy.tech/badge/kanban-python)](https://pepy.tech/project/kanban-python)
39
- [![Coverage Status](https://coveralls.io/repos/github/Zaloog/kanban-python/badge.svg?branch=refs/tags/v0.3.10)](https://coveralls.io/github/Zaloog/kanban-python?branch=refs/tags/v0.3.10)
18
+ [![Coverage Status](https://coveralls.io/repos/github/Zaloog/kanban-python/badge.svg?branch=main)](https://coveralls.io/github/Zaloog/kanban-python?branch=main)
40
19
  # kanban-python
41
20
 
42
21
  > A Terminal Kanban Application written in Python to boost your productivity :rocket:
@@ -51,9 +30,10 @@ my own Terminal Kanban Application since I preferred a more simple and guided wo
51
30
  **kanban-python** also comes with more features, like custom column creation,
52
31
  automatic scanning and customizable config file to support you being productive.
53
32
 
54
- This package was developed with [pyscaffold], which provides awesome project templates
33
+ This package was initially developed with [pyscaffold], which provides awesome project templates
55
34
  and takes over much of the boilerplate for python packaging.
56
35
  It was a great help for developing my first package and I can highly recommend it.
36
+ With version `0.5.X` the repository structure was changed to use [uv].
57
37
 
58
38
  ## Features
59
39
  <details><summary>Colorful and Interactive</summary>
@@ -142,10 +122,13 @@ You can install kanban-python with:
142
122
  python -m pip install kanban-python
143
123
  ```
144
124
 
145
- or using [pipx]:
125
+ or using [pipx] / [uv] / [rye]:
146
126
  ```bash
147
- pipx install kanban-python
127
+ pipx install kanban-python # using pipx
128
+ uv tool install kanban-python # using uv
129
+ rye install kanban-python # using rye
148
130
  ```
131
+ I recommend using pipx, rye or uv to install CLI Tools into an isolated environment.
149
132
 
150
133
  ## Usage
151
134
  After Installation of kanban-python, there are 5 commands available:
@@ -158,6 +141,10 @@ Is used to create a new kanban board i.e. it asks for a name and then creates a
158
141
  On first use of any command, the `pykanban.ini` configfile and the `kanban-python` folder will be created automatically.
159
142
  ![init_file](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_kanban_init.PNG)
160
143
 
144
+ You can create local boards in the current working directory by using the name `local` or the flags `-l` or `--local` when
145
+ using `kanban init`. kanban-python checks for local boards and updates the config file accordingly.
146
+ Local boards can only be accessed when using `kanban` in the same folder.
147
+
161
148
  ### Interact with Tasks/Boards
162
149
  ```bash
163
150
  kanban
@@ -173,7 +160,7 @@ or changing settings, your progress wont be saved.
173
160
  ```bash
174
161
  kanban scan
175
162
  ```
176
- After executing this command, kanban-python scans your current Directory recursively for the defined filetypes and searches for lines
163
+ After executing this command, kanban-python scans your current directory recursively for the defined filetypes and searches for lines
177
164
  that start with the pattern provided.
178
165
  ![scan_view](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_scan_view.PNG)
179
166
 
@@ -181,6 +168,8 @@ After confirmation to add the found tasks to table they will be added to the boa
181
168
  The filepath were the task was found will be added as description of the task.
182
169
  ![scan_table](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_scan_table.PNG)
183
170
 
171
+ You can also define a different path to scan with the `-p` or `--path` argument.
172
+
184
173
  ### Create Report
185
174
  ```bash
186
175
  kanban report
@@ -189,13 +178,15 @@ Goes over all your Boards and creates a single markdown file by checking the `Co
189
178
  Also shows a nice github-like contribution table for the current year.
190
179
  ![report](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_kanban_report.PNG)
191
180
 
181
+ You can define a different output path of the `pykanban.md` report file with the `-p` or `--path` argument.
182
+
192
183
  ### Change Settings
193
184
  ```bash
194
185
  kanban configure
195
186
  ```
196
187
  ![settings](https://raw.githubusercontent.com/Zaloog/kanban-python/main/images/image_kanban_configure.PNG)
197
188
 
198
- To create a new custom Columns, you have to edit the `pykanban.ini` manually and add a new column name + visibility status
189
+ To create a new custom Column, you have to edit the `pykanban.ini` manually and add a new column name + visibility status
199
190
  under the `settings.columns.visible` section. The other options are all customizable now via the new settings menu.
200
191
 
201
192
 
@@ -207,12 +198,7 @@ Also check the [Changelog](https://github.com/Zaloog/kanban-python/blob/main/CHA
207
198
  With release v0.3.0 kanban-python switched to the [XDG] Basedir Spec. So some file migrations and config edits might be
208
199
  needed to continue working with your already created boards if you update from `v0.2.X` to `v0.3.X`
209
200
 
210
- <!-- pyscaffold-notes -->
211
-
212
- ## Note
213
201
 
214
- This project has been set up using PyScaffold 4.5. For details and usage
215
- information on PyScaffold see https://pyscaffold.org/.
216
202
 
217
203
  [XDG]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
218
204
  [platformdirs]: https://platformdirs.readthedocs.io/en/latest/
@@ -220,3 +206,5 @@ information on PyScaffold see https://pyscaffold.org/.
220
206
  [pyscaffold]: https://pyscaffold.org/
221
207
  [rich]: https://github.com/Textualize/rich
222
208
  [pipx]: https://github.com/pypa/pipx
209
+ [uv]: https://docs.astral.sh/uv/
210
+ [rye]: https://rye.astral.sh
@@ -0,0 +1,55 @@
1
+ [project]
2
+ name = "kanban-python"
3
+ version = "0.5.1"
4
+ description = "Terminal Kanban App written in Python"
5
+ readme = "README.md"
6
+ authors = [
7
+ { name = "Zaloog", email = "gramslars@gmail.com" }
8
+ ]
9
+ requires-python = ">=3.9"
10
+ license = { file = "LICENSE.txt" }
11
+ dependencies = [
12
+ "platformdirs>=4.3.6",
13
+ "rich>=13.9.4",
14
+ ]
15
+
16
+ classifiers = [
17
+ "Development Status :: 3 - Alpha",
18
+ "License :: OSI Approved :: MIT License",
19
+ "Operating System :: OS Independent",
20
+ "Programming Language :: Python",
21
+ "Programming Language :: Python :: 3.9",
22
+ "Programming Language :: Python :: 3.10",
23
+ "Programming Language :: Python :: 3.11",
24
+ "Programming Language :: Python :: 3.12",
25
+ "Programming Language :: Python :: 3 :: Only",
26
+ ]
27
+
28
+ [project.urls]
29
+ Repository = "https://github.com/Zaloog/kanban-python"
30
+ Changelog = "https://github.com/Zaloog/kanban-python/blob/main/CHANGELOG.md"
31
+
32
+ [project.scripts]
33
+ kanban = "kanban_python.app:run"
34
+
35
+ [build-system]
36
+ requires = ["hatchling"]
37
+ build-backend = "hatchling.build"
38
+
39
+ [tool.pytest.ini_options]
40
+ addopts = "--cov src/kanban_python --cov-report term-missing --verbose --color=yes"
41
+ testpaths = ["tests"]
42
+
43
+ [tool.uv]
44
+ dev-dependencies = [
45
+ "freezegun>=1.5.1",
46
+ "pre-commit>=4.0.1",
47
+ "pytest>=8.3.3",
48
+ "pytest-cov>=6.0.0",
49
+ ]
50
+
51
+ [tool.hatch.metadata]
52
+ allow-direct-references = true
53
+
54
+ [tool.hatch.build.targets.wheel]
55
+ packages = ["src/kanban_python"]
@@ -0,0 +1,69 @@
1
+ import sys
2
+ from pathlib import Path
3
+
4
+ from kanban_python import cli_parser, config, controls, utils, constants
5
+
6
+ __author__ = "Zaloog"
7
+ __copyright__ = "Zaloog"
8
+ __license__ = "MIT"
9
+
10
+
11
+ def main(args):
12
+ args = cli_parser.parse_args(args)
13
+
14
+ if not config.check_config_exists():
15
+ config.create_init_config()
16
+ return
17
+
18
+ # Delete Local Entry if no local file present
19
+ if (not Path("pykanban.json").exists()) and ("local" in config.cfg.kanban_boards):
20
+ config.delete_board_from_config(board_name="local")
21
+
22
+ # New database creation
23
+ if args.command == "init":
24
+ utils.console.print("Starting new [blue]Kanban Board[/]:mechanical_arm:")
25
+ controls.create_new_db(local=args.local)
26
+
27
+ if args.command == "configure":
28
+ controls.change_settings()
29
+
30
+ if args.command == "scan":
31
+ controls.add_todos_to_board(path=Path(args.path) or Path.cwd())
32
+
33
+ if args.command == "report":
34
+ controls.create_report(
35
+ output_path=Path(args.path) or constants.REPORT_FILE_PATH
36
+ )
37
+ return
38
+
39
+ while True:
40
+ controls.show()
41
+ user_input = controls.get_user_action()
42
+
43
+ if user_input == 1:
44
+ controls.add_new_task_to_db()
45
+ elif user_input == 2:
46
+ controls.update_task_from_db()
47
+ elif user_input == 3:
48
+ controls.change_kanban_board()
49
+ elif user_input == 4:
50
+ controls.show_tasks()
51
+ elif user_input == 5:
52
+ controls.delete_kanban_board()
53
+ elif user_input == 6:
54
+ controls.change_settings()
55
+
56
+
57
+ def run():
58
+ """Calls :func:`main` passing the CLI arguments extracted from :obj:`sys.argv`
59
+
60
+ This function can be used as entry point to create console scripts with setuptools.
61
+ """
62
+ try:
63
+ main(sys.argv[1:])
64
+ except (KeyboardInterrupt, EOFError):
65
+ utils.console.print(utils.get_motivational_quote())
66
+
67
+
68
+ if __name__ == "__main__":
69
+ run()
@@ -0,0 +1,63 @@
1
+ import argparse
2
+
3
+ from kanban_python import __version__
4
+ from kanban_python.constants import REPORT_FILE_PATH
5
+
6
+
7
+ def parse_args(args):
8
+ """Parse command line parameters
9
+
10
+ Args:
11
+ args (List[str]): command line parameters as list of strings
12
+ (for example ``["--help"]``).
13
+
14
+ Returns:
15
+ :obj:`argparse.Namespace`: command line parameters namespace
16
+ """
17
+ parser = argparse.ArgumentParser(description="Usage Options")
18
+ parser.add_argument(
19
+ "-v",
20
+ "--version",
21
+ action="version",
22
+ version=f"kanban-python {__version__}",
23
+ )
24
+
25
+ command_parser = parser.add_subparsers(
26
+ title="commands", dest="command", description="available commands"
27
+ )
28
+
29
+ # Init
30
+ init_parser = command_parser.add_parser(
31
+ "init",
32
+ help="initialize a new board, use `--local`-flag to create in current working directory",
33
+ )
34
+ init_parser.add_argument(
35
+ "-l",
36
+ "--local",
37
+ help="create a local board in the current working directory, default:False",
38
+ action="store_true",
39
+ )
40
+
41
+ # Configure
42
+ command_parser.add_parser("configure", help="configure settings")
43
+
44
+ # Scan
45
+ scan_parser = command_parser.add_parser(
46
+ "scan", help="scan path for TODOs in files (default: `.`)"
47
+ )
48
+ scan_parser.add_argument(
49
+ "-p", "--path", required=False, help="path to scan (default: `.`)"
50
+ )
51
+
52
+ # Report
53
+ report_parser = command_parser.add_parser(
54
+ "report", help=f"create report in output path (default: {REPORT_FILE_PATH})"
55
+ )
56
+ report_parser.add_argument(
57
+ "-p",
58
+ "--path",
59
+ required=False,
60
+ help=f"path to save output to (default: {REPORT_FILE_PATH})",
61
+ )
62
+
63
+ return parser.parse_args(args)
@@ -189,4 +189,6 @@ def check_config_exists(path=CONFIG_FILE_PATH) -> bool:
189
189
 
190
190
 
191
191
  def get_json_path(boardname: str):
192
- return str(KANBAN_BOARDS_PATH / boardname / TASK_FILE_NAME)
192
+ if boardname == "local":
193
+ return (Path().cwd() / TASK_FILE_NAME).as_posix()
194
+ return (KANBAN_BOARDS_PATH / boardname / TASK_FILE_NAME).as_posix()