Skip to content

Stop letting code cleanup steps fail #72

@emmyoop

Description

@emmyoop

These steps to remove blank lines/spaces show errors in the output even though we want to ignore the errors.

# this step will fail on whitespace errors but also correct them
- name: "Remove Trailing Whitespace Via Pre-commit"
continue-on-error: true
run: |
pre-commit run trailing-whitespace --files .bumpversion.cfg CHANGELOG.md .changes/*
git status
# this step will fail on newline errors but also correct them
- name: "Removing Extra Newlines Via Pre-commit"
continue-on-error: true
run: |
pre-commit run end-of-file-fixer --files .bumpversion.cfg CHANGELOG.md .changes/*
git status

Add || true logic to the commands to stop the errors from propagating to the output as they are not true errors. Also remove the continue-on-error lines as they will no longer be relevant.

Metadata

Metadata

Assignees

No one assigned

    Labels

    tech_debtBehind-the-scenes changes, with little direct impact on end-user functionality

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions