piknik

Unnamed repository; edit this file 'description' to name the repository.
Info | Log | Files | Refs | README | LICENSE

commit 5d193d14d5afb0621c94dad47799f6fbda6b6d0a
parent c5451e1c49be519bab7582e3852319c4aca043a5
Author: lash <dev@holbrook.no>
Date:   Mon, 16 Jan 2023 11:02:37 +0000

Add accept flag, fix console script paths

Diffstat:
MCHANGELOG | 1+
MROADMAP | 1+
Mpiknik/runnable/mod.py | 5+++++
Msetup.cfg | 13++++++++-----
4 files changed, 15 insertions(+), 5 deletions(-)

diff --git a/CHANGELOG b/CHANGELOG @@ -1,6 +1,7 @@ - 0.2.3 * Add possibility to set dependencies between issues * Set default data directory under working directory + * Add accept shortcut flag to piknik-mod - 0.2.2 * Add html requirements to default install - 0.2.1 diff --git a/ROADMAP b/ROADMAP @@ -11,3 +11,4 @@ - target hash above - git tag - arbitrary string identifier + * Add renderer result tests for plain, html diff --git a/piknik/runnable/mod.py b/piknik/runnable/mod.py @@ -12,6 +12,7 @@ logg = logging.getLogger() argp = argparse.ArgumentParser() argp.add_argument('-d', type=str, help='Data directory') +argp.add_argument('--accept', action='store_true', help='Accept proposed issue') argp.add_argument('--block', action='store_true', help='Set issue as blocked') argp.add_argument('--unblock', action='store_true', help='Set issue as unblocked') argp.add_argument('--finish', action='store_true', help='Set issue as finished (alias of -s finish)') @@ -45,6 +46,10 @@ def main(): m(arg.issue_id) elif arg.finish: basket.state_finish(arg.issue_id) + elif arg.accept: + if basket.get_state(arg.issue_id) != 'PROPOSED': + raise ValueError('Issue already accepted') + basket.advance(arg.issue_id) for v in arg.tag: basket.tag(arg.issue_id, v) diff --git a/setup.cfg b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = piknik -version = 0.2.2 +version = 0.2.3 description = CLI issue tracker author = Louis Holbrook author_email = dev@holbrook.no @@ -29,10 +29,13 @@ include_package_data = True python_requires = >= 3.7 packages = piknik + piknik.store + piknik.render + piknik.runnable [options.entry_points] console_scripts = - piknik-add = piknik.runnable.add.py:main - piknik-mod = piknik.runnable.mod.py:main - piknik-show = piknik.runnable.show.py:main - piknik-comment = piknik.runnable.comment.py:main + piknik-add = piknik.runnable.add:main + piknik-mod = piknik.runnable.mod:main + piknik-show = piknik.runnable.show:main + piknik-comment = piknik.runnable.comment:main