roboherd 0.1.10__py3-none-any.whl → 0.1.11__py3-none-any.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.

Potentially problematic release.


This version of roboherd might be problematic. Click here for more details.

roboherd/__main__.py CHANGED
@@ -11,12 +11,13 @@ from roboherd.herd.manager import HerdManager
11
11
  from roboherd.util import create_connection
12
12
  from roboherd.register import register as run_register
13
13
  from roboherd.validators import validators
14
+ from roboherd.version import __version__
14
15
 
15
16
  logging.basicConfig(level=logging.INFO)
16
17
  logging.captureWarnings(True)
17
18
 
18
19
 
19
- @click.group()
20
+ @click.group(invoke_without_command=True)
20
21
  @click.option(
21
22
  "--connection_string",
22
23
  default=None,
@@ -28,9 +29,22 @@ logging.captureWarnings(True)
28
29
  help="Base url to create cows with",
29
30
  )
30
31
  @click.option("--config_file", default="roboherd.toml", help="Configuration file")
32
+ @click.option(
33
+ "--version", is_flag=True, default=False, help="display version then exit"
34
+ )
31
35
  @click.pass_context
32
- def main(ctx: click.Context, connection_string: str, base_url: str, config_file: str):
36
+ def main(
37
+ ctx: click.Context,
38
+ connection_string: str,
39
+ base_url: str,
40
+ config_file: str,
41
+ version: bool,
42
+ ):
33
43
  """Configuration is usually loaded from the config_file. These options can be overwritten by passing as a command line argument."""
44
+ if version:
45
+ print(f"roboherd version: {__version__}")
46
+ exit(0)
47
+
34
48
  settings = dynaconf.Dynaconf(
35
49
  settings_files=[config_file],
36
50
  envvar_prefix="ROBOHERD",
@@ -51,6 +65,8 @@ def main(ctx: click.Context, connection_string: str, base_url: str, config_file:
51
65
  else:
52
66
  ctx.obj["base_url"] = settings.base_url # type: ignore
53
67
 
68
+ print("Please specify a command")
69
+
54
70
 
55
71
  @main.command()
56
72
  @click.option("--fail", is_flag=True, default=False, help="Fail if actors do not exist")
roboherd/version.py ADDED
@@ -0,0 +1 @@
1
+ __version__ = "0.1.11"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: roboherd
3
- Version: 0.1.10
3
+ Version: 0.1.11
4
4
  Summary: A Fediverse bot framework
5
5
  Project-URL: Documentation, https://bovine.codeberg.page/roboherd/
6
6
  Project-URL: Repository, https://codeberg.org/bovine/roboherd
@@ -1,9 +1,10 @@
1
1
  roboherd/__init__.py,sha256=E89YtYyL77iJDJJkHS4Pn0JdTbmkmQS7Cp_XPqpRgx8,533
2
- roboherd/__main__.py,sha256=DxxPrubMXNp_rqE-1S-S7pCn065CfQo2uHmxP1FWZU4,3655
2
+ roboherd/__main__.py,sha256=Bix6QLAXXs9zh3G8UOPHbq33QDhOCn4bNB7P0z1_9N0,3979
3
3
  roboherd/register.py,sha256=jnnHv-epeyXHcmmulxJoHqT7uWmb_efFnCbdxojKOBM,1044
4
4
  roboherd/test_validators.py,sha256=UiFgJkutmXBLjGpdLP2IBYCEf75quwnRHX7Z51G8Xqo,222
5
5
  roboherd/util.py,sha256=gG8Scht1xRfauUOdL7GrLf9e3UO-j88X2wEdc1Ymm3o,1748
6
6
  roboherd/validators.py,sha256=2mc43ZGwFazp4f3B9J4RxZCU4Y_ErSNotib8MnYVtmY,140
7
+ roboherd/version.py,sha256=nllDrH0jyChMuuYrK0CC55iTBKUNTUjejtcwxyUF2EQ,23
7
8
  roboherd/annotations/__init__.py,sha256=BrP5UWiVnh8FwmHc6wEY3G69BStidGUpF8uP4Ea5-dg,1140
8
9
  roboherd/annotations/bovine.py,sha256=cFLUSFzTulikNjZb1lLq5v4tGjL1i7_dR3H6wimegCg,2322
9
10
  roboherd/annotations/common.py,sha256=n5rm8WTgsg116RczKdzm_VoPg1mBk_IMf2V7l8UgWKQ,1351
@@ -38,7 +39,7 @@ roboherd/herd/manager/load.py,sha256=BoeBID2UGP--sIKwITABQkQv2lMc9Y8pyp7_nleu2bw
38
39
  roboherd/herd/manager/test_config.py,sha256=I2EP7nEUdBVO8Wqot7SRhzp5UZFr5oGIuFS7cNB2iFk,1745
39
40
  roboherd/herd/manager/test_load.py,sha256=zyu5LIChMfTnxu_tYK63-bSOHYn1K1zUlbDY5DkE3GY,514
40
41
  roboherd/herd/manager/test_manager.py,sha256=9pSMaH7zmN-zagYCIBpQcV3Q0sBT7XZSCvsmLVC0rOI,1047
41
- roboherd-0.1.10.dist-info/METADATA,sha256=rYVd_FKmmzULegTCdV9Xvp8W4Vn-DcKn_xokqfoUPPA,2206
42
- roboherd-0.1.10.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
43
- roboherd-0.1.10.dist-info/entry_points.txt,sha256=WebdVUmh8Ot-FupKJY6Du8LuFbmezt9yoy2UICqV3bE,52
44
- roboherd-0.1.10.dist-info/RECORD,,
42
+ roboherd-0.1.11.dist-info/METADATA,sha256=7l6P2qnsbNozntECa2Otgggvx9TeMV_l5dmhpap8iIY,2206
43
+ roboherd-0.1.11.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
44
+ roboherd-0.1.11.dist-info/entry_points.txt,sha256=WebdVUmh8Ot-FupKJY6Du8LuFbmezt9yoy2UICqV3bE,52
45
+ roboherd-0.1.11.dist-info/RECORD,,