Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
file-text

GitHub Action

check-crlf

v1.1.2

check-crlf

file-text

check-crlf

Checks for non-binary files with CRLF endings in given path

Installation

Copy and paste the following snippet into your .yml file.

              

- name: check-crlf

uses: erclu/[email protected]

Learn more about this action in erclu/check-crlf

Choose a version

GitHub Action to check for files with CRLF line endings

GitHub Action to add to a workflow, to keep in check those windows developers who have given up understanding git's autocrlf setting and/or forget to handle line endings on their side.

Uses grep on a docker container.

By default checks all files in the repository (excluding the .git folder), but can be given a list of separate directories to check.

Example

name: Example usage

on: push

jobs:
  example-workflow:
    name: Example workflow using the Check CRLF action
    runs-on: ubuntu-latest

    steps:
      - name: Checkout repository contents
        uses: actions/checkout@v1

      - name: Use action to check for CRLF endings
        uses: erclu/check-crlf@v1
        with: # omit this mapping to use default path
          path: ./a-custom-path

Contributors

Most of the work was done by @Rotendahl, I mainly copy-pasted stuff from stack overflow :)