Skip to content

Commit

Permalink
perf: opt to log command args
Browse files Browse the repository at this point in the history
Signed-off-by: msclock <msclock@qq.com>
  • Loading branch information
msclock committed Jan 3, 2024
1 parent 3b63009 commit 8bde657
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions src/sphinx_deployment/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ def create_command(
version: str,
) -> None:
logger.debug(
f"create args: {input_path} {output_path} {push} {remote} {branch} {message} {version}"
f"create args: {input_path} {output_path} {remote} {branch} {message} {push} {version}"
)
_ = sync_remote(remote, branch)

Expand Down Expand Up @@ -419,7 +419,9 @@ def delete_command(
push: bool,
delete: typing.Tuple[str],
) -> None:
logger.debug(f"delete args: {input_path} {output_path} {remote} {branch} {push}")
logger.debug(
f"delete args: {input_path} {output_path} {remote} {branch} {message} {push} {delete}"
)
_ = sync_remote(remote, branch)

version_path = Path(output_path) / "versions.json"
Expand Down Expand Up @@ -479,7 +481,7 @@ def default_command(
version: str,
) -> None:
logger.debug(
f"default args: {input_path} {output_path} {remote} {branch} {message} {push}"
f"default args: {input_path} {output_path} {remote} {branch} {message} {push} {version}"
)

version_path = Path(output_path) / "versions.json"
Expand Down Expand Up @@ -545,7 +547,7 @@ def rename_command(
dst: str,
) -> None:
logger.debug(
f"rename args: {input_path} {output_path} {remote} {branch} {push} {src} {dst}"
f"rename args: {input_path} {output_path} {remote} {branch} {message} {push} {src} {dst}"
)

if src == dst:
Expand Down Expand Up @@ -626,7 +628,7 @@ def rename_command(
@opt_remote
@opt_branch
def list_command(input_path: str, output_path: str, remote: str, branch: str) -> None:
logger.debug(f"list {input_path} {output_path} {remote}/{branch}")
logger.debug(f"list args: {input_path} {output_path} {remote} {branch}")
_ = sync_remote(remote, branch)

version_path = Path(output_path) / "versions.json"
Expand All @@ -643,7 +645,7 @@ def list_command(input_path: str, output_path: str, remote: str, branch: str) ->
def serve(
input_path: str, output_path: str, remote: str, branch: str, port: int
) -> None:
logger.debug(f"serve {input_path} {output_path} {remote}/{branch}")
logger.debug(f"serve args: {input_path} {output_path} {remote} {branch} {port}")
_ = sync_remote(remote, branch)

version_path = Path(output_path) / "versions.json"
Expand Down

0 comments on commit 8bde657

Please sign in to comment.