Skip to content

Commit

Permalink
readd check for tabs in sources
Browse files Browse the repository at this point in the history
  • Loading branch information
ernstblechaPT authored and azoitl committed Jun 26, 2024
1 parent b8bf0bb commit c84e3b4
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
20 changes: 20 additions & 0 deletions .github/workflows/tab_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# This starter workflow is for a CMake project running on multiple platforms. There is a different starter workflow if you just want a single platform.
# See: https://github.com/actions/starter-workflows/blob/main/ci/cmake-single-platform.yml
name: Check for Tabs

on:
push:
branches: [ "release", "develop", "freeze" ]
pull_request:
branches: [ "release", "develop", "freeze" ]

jobs:
build:
runs-on: ubuntu-latest
container: quay.io/eclipse4diac/4diac-fortebuildcontainer:latest

steps:
- uses: actions/[email protected]

- name: Test for Tabs
run: tests/findTabs.sh
3 changes: 2 additions & 1 deletion tests/findTabs.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/bin/bash

if [ "$WORKSPACE" == "" ]
then
Expand All @@ -13,7 +14,7 @@ do
echo $folder
done

FOUND_TABS=$(grep -r "$(printf '\t')" $FOLDERS) #using -P with grep gave the error: invalid UTF-8 byte sequence in input
FOUND_TABS=$(grep -r --include \*.h --include \*.cpp "$(printf '\t')" $FOLDERS) #using -P with grep gave the error: invalid UTF-8 byte sequence in input


if [ "$FOUND_TABS" == "" ]
Expand Down

0 comments on commit c84e3b4

Please sign in to comment.