Skip to content
This repository has been archived by the owner on Sep 5, 2022. It is now read-only.

Commit

Permalink
Create group for data extraction tasks & add all non-db commands
Browse files Browse the repository at this point in the history
  • Loading branch information
S1SYPHOS committed May 8, 2021
1 parent f4b7c91 commit 9fbc8ce
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,16 @@ def flush(config):
click.echo(' done.')


@cli.group()
def ex():
"""Extraction tasks"""
pass


@click.option('-c', '--config', help='Path to configuration file.')
@click.option('-y', '--year', help='Year.')
@click.option('-q', '--quarter', help='Quarter.')
@cli.command()
@ex.command()
def match(
config: str,
year: int = None,
Expand All @@ -112,7 +118,7 @@ def match(
@click.option('-c', '--config', help='Path to configuration file.')
@click.option('-y', '--year', help='Year.')
@click.option('-q', '--quarter', help='Quarter.')
@cli.command()
@ex.command()
def rank(
config: str,
year: int = None,
Expand All @@ -134,7 +140,7 @@ def rank(

@click.option('-c', '--config', help='Path to configuration file.')
@click.option('-d', '--date', help='Cutoff date in ISO date format, eg \'YYYY-MM-DD\'. Default: today two years ago')
@cli.command()
@ex.command()
def contacts(config: str, date: str = None):
"""Generates mailmerge-ready contact list"""

Expand Down

0 comments on commit 9fbc8ce

Please sign in to comment.