Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use GitHub Action instead of a filter for CRLF normalization #106

Merged
merged 4 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# By default, auto detect text files and perform LF normalization
* text=auto eol=lf

# VBA extensions - Enforce CRLF using a filter
# To make sure the filter is active, run the command: git config include.path ../.gitconfig
*.bas -text filter=crlf
*.cls -text filter=crlf
*.frm -text filter=crlf
# VBA extensions - Prevent LF normalization
*.bas -text diff
*.cls -text diff
*.frm -text diff

# VBA extensions - Mark as binary
*.frx binary

# AutoHotKey
*.ahk -text filter=crlf
*.ahk -text diff
2 changes: 0 additions & 2 deletions .gitconfig

This file was deleted.

22 changes: 22 additions & 0 deletions .github/workflows/enforce_crlf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Enforce-CRLF

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

permissions:
contents: write

jobs:
enforce-crlf:
runs-on: ubuntu-latest
steps:
- name: Enforce CRLF action
uses: DecimalTurn/Enforce-CRLF@08706ea4cc4a3de32d8b3c769686355a22d69e84 #v1.1.2
with:
extensions: .bas, .frm, .cls
do-checkout: true
do-push: true

Loading