Skip to content

cisagov/action-blacken-python2

action-blacken-python2

GitHub Build Status License CodeQL

This is a GitHub Docker container action to format Python 2 source code using black.

Warning

This action is written to make it easier to format Python 2 source code, but black will format any Python code in a project this action is run against.

Note

Changes made by this action are only available for the workflow job that runs this action. A consuming workflow job would need to commit and push the modified files for them to persist.

Usage

Inputs

None.

Outputs

None.

Sample GitHub Actions workflow

This GitHub action requires no permissions for its functionality.

---
name: The workflow

on:
  push:

jobs:
  my_job:
    # This job does not need any permissions
    permissions: {}
    runs-on: ubuntu-latest
    steps:
      - name: Checkout the Python 2 project
        uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
      - name: Format the Python 2 project
        uses: cisagov/action-blacken-python2@v1.0.0

Contributing

We welcome contributions! Please see CONTRIBUTING.md for details.

License

This project is in the worldwide public domain.

This project is in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication.

All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.

About

No description, website, or topics provided.

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 12