Skip to content

Commit

Permalink
Merge pull request #168 from CrowdStrike/caracara-0.9.x
Browse files Browse the repository at this point in the history
Bumps Caracara to the 0.9.x branch and removes setuptools requirement
  • Loading branch information
ChristopherHammond13 authored Dec 16, 2024
2 parents c7fe337 + 3f856ba commit 419153c
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 39 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/code-quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
codequality:
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
Expand Down
8 changes: 5 additions & 3 deletions falcon_toolkit/common/meta.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
This is where all functions and variable setting that are based on application metadata live.
"""

import pkg_resources
import importlib.metadata

# Derive the version via pkg_resources, which is populated based on the version in pyproject.toml
__version__ = pkg_resources.get_distribution(__name__.split(".", maxsplit=1)[0]).version
# Derive the version via importlib.metadata, which is populated based on the version in
# pyproject.toml. We used to use pkg_resources for this, but using importlib.metadata means
# that setuptools is no longer required.
__version__ = importlib.metadata.version("falcon-toolkit")
6 changes: 5 additions & 1 deletion falcon_toolkit/falcon.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
OLD_DEFAULT_CONFIG_DIR,
)
from falcon_toolkit.common.logging_config import configure_logger
from falcon_toolkit.common.meta import __version__
from falcon_toolkit.common.utils import configure_data_dir
from falcon_toolkit.containment.cli import cli_containment
from falcon_toolkit.hosts.cli import cli_host_search
Expand Down Expand Up @@ -135,7 +136,10 @@ def cli(

# Configure context that can be passed down to other options
ctx.ensure_object(dict)
click.echo(click.style("Falcon Toolkit", fg="blue", bold=True))
click.echo(
click.style("Falcon Toolkit", fg="blue", bold=True)
+ click.style(f" v{__version__}", fg="black", bold=True)
)
hyperlink = build_file_hyperlink(config_path, config_path, "falcon_config_path")
click.echo(click.style(f"Configuration Directory: {hyperlink}", fg="black"))
if verbose:
Expand Down
47 changes: 15 additions & 32 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ classifiers = [

[tool.poetry.dependencies]
python = "^3.9"
caracara = "^0.8.0"
caracara = "^0.9.0"
click = "^8.1.3"
click-option-group = "^0.5.6"
click-spinner = "^0.1.10"
Expand All @@ -41,7 +41,6 @@ keyring = ">=24,<26"
platformdirs = "^4.2.0"
tabulate = "^0.9.0"
prompt-toolkit = "^3.0.43"
setuptools = "^69.0"

[tool.poetry.scripts]
falcon = "falcon_toolkit.falcon:cli"
Expand Down

0 comments on commit 419153c

Please sign in to comment.