Skip to content

Anadea/pre-commit-config-shellcheck

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

pre-commit-config-shellcheck documentation

GitHub_ Coveralls_ License_ Version_ Supported Python version_ Package format_ Python wheel support_ Package status_

pre-commit-config-shellcheck is a tool for checking entry points in the pre-commit config with ShellCheck.

Installation

In order to use the tool you should first clone it from the source:

$ git clone https://github.com/Anadea/pre-commit-config-shellcheck.git

Then you should install project dependencies with

$ python ./setup.py install

or

$ pip install pre-commit-config-shellcheck

The installation is done and as simple as that.

Usage

To run the program you should start it from the terminal and provide a config file to check:

$ pre_commit_config_shellcheck.py .pre-commit-config.yaml

You could change a default ShellCheck call with directory access with the -s or --shellcheck argument:

$ pre_commit_config_shellcheck.py .pre-commit-config.yaml -s /bin/shellcheck

The output from tool usage is sent to the stdout or stderr depending on the operation result.

Usage as a pre-commit hook

Also, it can be used as a pre-commit hook out of the box. Just add it to yours .pre-commit-config.yaml:

- repo: "https://github.com/Anadea/pre-commit-config-shellcheck"
  rev: "0.3.4"
    hooks:
      - id: "pre-commit-config-shellcheck"

Usage as GitHub action

Also, it can be used as a GitHub action out of the box. Just add it to yours workflow:

- name: "pre-commit-config-shellcheck"
  uses: "actions/pre-commit-config-shellcheck@0.3.4"
  id: "pre-commit-config-shellcheck"
  with:
    config: ".pre-commit-config.yaml"

Contributing

cp .env.example .env
  • Install development dependencies:
make install
  • Create your fix/feature branch:
git checkout -b my-new-fix-or-feature
  • Check code style and moreover:
make check
  • Run tests:
make test
  • Push to the branch:
git push origin my-new-fix-or-feature

Licensing

pre-commit-config-shellcheck uses the MIT license. Please check the MIT-LICENSE file for more details.

Contacts

Project Website: https://github.com/Anadea/pre-commit-config-shellcheck/

Author: Anadea

For contributors list see CONTRIBUTORS file.