Skip to content

Commit

Permalink
_cli: emit .sigstore.json by default (#1007)
Browse files Browse the repository at this point in the history
* _cli: emit .sigstore.json by default

Closes #814.

Signed-off-by: William Woodruff <[email protected]>

* CHANGELOG: record changes

Signed-off-by: William Woodruff <[email protected]>

* README: update `--help`

Signed-off-by: William Woodruff <[email protected]>

---------

Signed-off-by: William Woodruff <[email protected]>
  • Loading branch information
woodruffw authored May 13, 2024
1 parent 7d483ae commit a86b7cb
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ All versions prior to 0.9.0 are untracked.
* **BREAKING API CHANGE**: `Verifier.verify(...)` now takes a `sigstore.models.Bundle`,
instead of a `VerificationMaterials` ([#937](https://github.com/sigstore/sigstore-python/pull/937))

* **BREAKING CLI CHANGE**: `sigstore sign` now emits `{input}.sigstore.json`
by default instead of `{input}.sigstore`, per the client specification
([#1007](https://github.com/sigstore/sigstore-python/pull/1007))

* sigstore-python now requires inclusion proofs in all signing and verification
flows, regardless of bundle version of input types. Inputs that do not
have an inclusion proof (such as detached materials) cause an online lookup
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@ OpenID Connect options:
False)

Output options:
--no-default-files Don't emit the default output files ({input}.sigstore)
(default: False)
--no-default-files Don't emit the default output files
({input}.sigstore.json) (default: False)
--signature FILE, --output-signature FILE
Write a single signature to the given file; does not
work with multiple input files (default: None)
Expand Down
4 changes: 2 additions & 2 deletions sigstore/_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ def _parser() -> argparse.ArgumentParser:
"--no-default-files",
action="store_true",
default=_boolify_env("SIGSTORE_NO_DEFAULT_FILES"),
help="Don't emit the default output files ({input}.sigstore)",
help="Don't emit the default output files ({input}.sigstore.json)",
)
output_options.add_argument(
"--signature",
Expand Down Expand Up @@ -559,7 +559,7 @@ def _sign(args: argparse.Namespace) -> None:
output_dir.mkdir(parents=True, exist_ok=True)

if not bundle and not args.no_default_files:
bundle = output_dir / f"{file.name}.sigstore"
bundle = output_dir / f"{file.name}.sigstore.json"

if not args.overwrite:
extants = []
Expand Down

0 comments on commit a86b7cb

Please sign in to comment.