Skip to content

Commit

Permalink
Merge pull request #37 from mdellweg/update_codebase
Browse files Browse the repository at this point in the history
Update the codebase
  • Loading branch information
mdellweg committed Nov 11, 2022
2 parents 7253f0b + beb6b3a commit 1303bf0
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 31 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
- name: Lint code
run: make lint
test:
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
needs:
- lint
strategy:
Expand All @@ -51,16 +51,16 @@ jobs:
- python: "3.9"
image_tag: "nightly"
- python: "3.6"
image_tag: "3.16"
image_tag: "3.21"
- python: "3.7"
image_tag: "3.15"
image_tag: "3.20"
- python: "3.8"
image_tag: "3.14"
image_tag: "3.19"
- python: "3.9"
image_tag: "3.13"
image_tag: "3.18"
- python: "3.10"
pulp_cli: "0.13.0"
image_tag: "3.12"
pulp_cli: "0.15.0"
image_tag: "3.17"
steps:
- uses: actions/checkout@v2
- name: Set up Python
Expand Down
22 changes: 11 additions & 11 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,24 @@ env:

jobs:
test:
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
- python: "3.9"
image_tag: "nightly"
- python: "3.9"
image_tag: "3.16"
- python: "3.8"
image_tag: "3.15"
- python: "3.7"
image_tag: "3.14"
- python: "3.6"
image_tag: "3.13"
- python: "3.6"
pulp_cli: "0.12.0"
image_tag: "3.12"
image_tag: "3.21"
- python: "3.7"
image_tag: "3.20"
- python: "3.8"
image_tag: "3.19"
- python: "3.9"
image_tag: "3.18"
- python: "3.10"
pulp_cli: "0.15.0"
image_tag: "3.17"
steps:
- uses: actions/checkout@v2
- name: Set up Python
Expand Down
5 changes: 3 additions & 2 deletions pulpcore/cli/deb/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from pulpcore.cli.common import main
from pulpcore.cli.common.context import PluginRequirement, PulpContext, pass_pulp_context
from pulpcore.cli.common.context import PluginRequirement
from pulpcore.cli.common.generic import PulpCLIContext, pass_pulp_context

from pulpcore.cli.deb.distribution import distribution
from pulpcore.cli.deb.publication import publication
Expand All @@ -9,7 +10,7 @@

@main.group()
@pass_pulp_context
def deb(pulp_ctx: PulpContext) -> None:
def deb(pulp_ctx: PulpCLIContext) -> None:
pulp_ctx.needs_plugin(PluginRequirement("deb"))


Expand Down
5 changes: 3 additions & 2 deletions pulpcore/cli/deb/distribution.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import gettext

import click
from pulpcore.cli.common.context import PulpContext, pass_pulp_context
from pulpcore.cli.common.generic import (
PulpCLIContext,
base_path_contains_option,
base_path_option,
create_command,
Expand All @@ -12,6 +12,7 @@
label_select_option,
list_command,
name_option,
pass_pulp_context,
resource_option,
show_command,
update_command,
Expand Down Expand Up @@ -44,7 +45,7 @@
)
@pass_pulp_context
@click.pass_context
def distribution(ctx: click.Context, pulp_ctx: PulpContext, distribution_type: str) -> None:
def distribution(ctx: click.Context, pulp_ctx: PulpCLIContext, distribution_type: str) -> None:
if distribution_type == "apt":
ctx.obj = PulpAptDistributionContext(pulp_ctx)
else:
Expand Down
5 changes: 3 additions & 2 deletions pulpcore/cli/deb/publication.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import gettext

import click
from pulpcore.cli.common.context import PulpContext, pass_pulp_context
from pulpcore.cli.common.generic import (
PulpCLIContext,
create_command,
destroy_command,
href_option,
list_command,
pass_pulp_context,
publication_filter_options,
resource_option,
show_command,
Expand Down Expand Up @@ -40,7 +41,7 @@
)
@pass_pulp_context
@click.pass_context
def publication(ctx: click.Context, pulp_ctx: PulpContext, publication_type: str) -> None:
def publication(ctx: click.Context, pulp_ctx: PulpCLIContext, publication_type: str) -> None:
if publication_type == "apt":
ctx.obj = PulpAptPublicationContext(pulp_ctx)
elif publication_type == "verbatim":
Expand Down
5 changes: 3 additions & 2 deletions pulpcore/cli/deb/remote.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import click
from pulpcore.cli.common.context import PulpContext, pass_pulp_context
from pulpcore.cli.common.generic import (
PulpCLIContext,
common_remote_create_options,
common_remote_update_options,
create_command,
Expand All @@ -10,6 +10,7 @@
label_select_option,
list_command,
name_option,
pass_pulp_context,
show_command,
update_command,
)
Expand All @@ -31,7 +32,7 @@
)
@pass_pulp_context
@click.pass_context
def remote(ctx: click.Context, pulp_ctx: PulpContext, remote_type: str) -> None:
def remote(ctx: click.Context, pulp_ctx: PulpCLIContext, remote_type: str) -> None:
if remote_type == "apt":
ctx.obj = PulpAptRemoteContext(pulp_ctx)
else:
Expand Down
8 changes: 4 additions & 4 deletions pulpcore/cli/deb/repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@
from pulpcore.cli.common.context import (
EntityFieldDefinition,
PluginRequirement,
PulpContext,
PulpEntityContext,
PulpRepositoryContext,
pass_pulp_context,
pass_repository_context,
)
from pulpcore.cli.common.generic import (
PulpCLIContext,
create_command,
destroy_command,
href_option,
label_command,
label_select_option,
list_command,
name_option,
pass_pulp_context,
pass_repository_context,
pulp_option,
repository_href_option,
repository_option,
Expand Down Expand Up @@ -55,7 +55,7 @@
)
@pass_pulp_context
@click.pass_context
def repository(ctx: click.Context, pulp_ctx: PulpContext, repo_type: str) -> None:
def repository(ctx: click.Context, pulp_ctx: PulpCLIContext, repo_type: str) -> None:
if repo_type == "apt":
ctx.obj = PulpAptRepositoryContext(pulp_ctx)
else:
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
package_data={"": ["py.typed", "locale/*/LC_MESSAGES/*.mo"]},
python_requires=">=3.6",
install_requires=[
"pulp-cli>=0.13.0",
"pulp-cli>=0.15.0",
],
entry_points={
"pulp_cli.plugins": [f"{name}={module}" for name, module in plugin_entry_points],
Expand Down

0 comments on commit 1303bf0

Please sign in to comment.