Skip to content

CompareDocs: Returns 1 if comparison failed; 2 if bad args#301

Draft
bact wants to merge 4 commits into
spdx:masterfrom
bact:exit-code-comparedocs
Draft

CompareDocs: Returns 1 if comparison failed; 2 if bad args#301
bact wants to merge 4 commits into
spdx:masterfrom
bact:exit-code-comparedocs

Conversation

@bact

@bact bact commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

Implement exit codes as proposed in #299

Note

This PR requires ExitCode, introduced in PR #300.
Should merge #300 before this one.

bact added 4 commits July 16, 2026 13:57
run() returns an exit-status int instead of calling System.exit()
directly. No behavior change.

Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
USAGE_ERROR_STATUS=2 for bad invocation (missing args, invalid file type, invalid file name);

ERROR_STATUS=1 stays for invalid or unreadable SPDX documents.

Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
@bact bact added the enhancement New feature or request label Jul 16, 2026
@bact
bact marked this pull request as draft July 16, 2026 14:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant