Repository: tellor-io/telliot-feeds (language: python)

Issue:
Make setup easier
- [ ] change repo/pkg name to telliot
- [x] change CLI entry point name to telliot, change telliot-core to telliot-core
- [x] move config cmd to telliot/telliot-feeds
- [x] have the cli prompt the user on install for pk and rpc endpoint
- [x] prompts the user to setup chained-accounts as well
- [x] all setup through CLI, reduces need to navigate file system to the /telliot folder


Discussion / hints:
Some of this handled in #377 
Confusing default on if you want to change config in CLI (Y/N default is N)

Fix patch:
diff --git a/setup.cfg b/setup.cfg
index b25ebe72..3ca90529 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -50,4 +50,4 @@ where = src
 
 [options.entry_points]
 console_scripts =
-    telliot-feeds  = telliot_feeds.cli.main:main
+    telliot  = telliot_feeds.cli.main:main
diff --git a/src/telliot_feeds/cli/commands/config.py b/src/telliot_feeds/cli/commands/config.py
new file mode 100644
index 00000000..7a60e2c9
--- /dev/null
+++ b/src/telliot_feeds/cli/commands/config.py
@@ -0,0 +1,24 @@
+import click
+import yaml
+from telliot_core.apps.telliot_config import TelliotConfig
+
+
+@click.group()
+def config() -> None:
+    """Manage Telliot configuration."""
+    pass
+
+
+@config.command()
+def init() -> None:
+    """Create initial configuration files."""
+    _ = TelliotConfig()
+
+
+@config.command()
+def show() -> None:
+    """Show current configuration."""
+    cfg = TelliotConfig()
+    state = cfg.get_state()
+
+    print(yaml.dump(state, sort_keys=False))
diff --git a/src/telliot_feeds/cli/main.py b/src/telliot_feeds/cli/main.py
index 1cb774e7..460e1990 100644
--- a/src/telliot_feeds/cli/main.py
+++ b/src/telliot_feeds/cli/main.py
@@ -9,6 +9,7 @@
 from click.core import Context
 
 from telliot_feeds.cli.commands.catalog import catalog
+from telliot_feeds.cli.commands.config import config
 from telliot_feeds.cli.commands.integrations import integrations
 from telliot_feeds.cli.commands.query import query
 from telliot_feeds.cli.commands.report import report
@@ -67,6 +68,7 @@ def main(
 main.add_command(catalog)
 main.add_command(settle)
 main.add_command(integrations)
+main.add_command(config)
 
 if __name__ == "__main__":
     main()
diff --git a/tox.ini b/tox.ini
index a4404648..b4c6bc87 100644
--- a/tox.ini
+++ b/tox.ini
@@ -23,7 +23,7 @@ commands =
     pip install PyYAML==6.0
     pip install multicall
     pip install simple-term-menu
-    telliot --version
+    telliot-core --version
     - pytest --cov --cov-report xml
 
 [testenv:style]


Test patch:
diff --git a/tests/cli/test_cli.py b/tests/cli/test_cli.py
index 3c6176f8..cfb6b1ba 100644
--- a/tests/cli/test_cli.py
+++ b/tests/cli/test_cli.py
@@ -160,3 +160,18 @@ def test_query_info():
     result = runner.invoke(cli_main, ["--test_config", "query", "status", "-qt", "eth-usd-spot"])
     assert not result.exception
     assert "Current value" in result.stdout
+
+
+def test_config_show():
+    """Make sure config is running"""
+    runner = CliRunner()
+    result = runner.invoke(cli_main, ["--test-config", "config", "show"])
+    assert not result.exception
+
+
+def test_config_cmd():
+    """Test telliot_core CLI command: report."""
+    runner = CliRunner()
+    result = runner.invoke(cli_main, ["config", "init"])
+    assert not result.exception
+    print(result.stdout)