Skip to content

Commit

Permalink
change ${{ github.action_path }} with $GITHUB_ACTION_PATH (#160)
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosala authored Sep 5, 2023
1 parent e80c039 commit 3a896db
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,18 +111,18 @@ runs:
fi
fi
if [[ "${{runner.os}}" == "macOS" ]]; then
python3 -m venv '${{ github.action_path }}/venv'
source '${{ github.action_path }}/venv/bin/activate'
python3 -m venv "$GITHUB_ACTION_PATH/venv"
source "$GITHUB_ACTION_PATH/venv/bin/activate"
fi
python3 -m pip install -r '${{ github.action_path }}/requirements.txt'
python3 -m pip install -r "$GITHUB_ACTION_PATH/requirements.txt"
clang-tools -i ${{ inputs.version }} -b
- name: Run cpp-linter
id: cpp-linter
shell: bash
run: |
if [[ "${{runner.os}}" == "macOS" ]];then
source '${{ github.action_path }}/venv/bin/activate'
if [[ "${{runner.os}}" == "macOS" ]]; then
source "$GITHUB_ACTION_PATH/venv/bin/activate"
fi
cpp-linter \
--style="${{ inputs.style }}" \
Expand Down

2 comments on commit 3a896db

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cpp-Linter Report ⚠️

Some files did not pass the configured checks!

clang-format reports: 2 file(s) not formatted
  • demo/demo.cpp
  • demo/demo.hpp
clang-tidy reports: 7 concern(s)
  • demo/demo.cpp

    /demo/demo.cpp:3:10: warning: [modernize-deprecated-headers]

    inclusion of deprecated C++ header 'stdio.h'; consider using 'cstdio' instead

    #include <stdio.h>
             ^~~~~~~~~
             <cstdio>

    /demo/demo.cpp:8:5: warning: [modernize-use-trailing-return-type]

    use a trailing return type for this function

    int main(){
    ~~~ ^
    auto       -> int

    /demo/demo.cpp:10:13: warning: [readability-braces-around-statements]

    statement should be inside braces

        for (;;) break;
                ^
                 {

    /demo/demo.cpp:13:5: warning: [cppcoreguidelines-pro-type-vararg]

    do not call c-style vararg functions

        printf("Hello world!\n");
        ^
  • demo/demo.hpp

    /demo/demo.hpp:6:11: warning: [modernize-use-default-member-init]

    use default member initializer for 'useless'

        char* useless;
              ^
                     {"\0"}

    /demo/demo.hpp:7:9: warning: [modernize-use-default-member-init]

    use default member initializer for 'numb'

        int numb;
            ^
                {0}

    /demo/demo.hpp:11:11: warning: [modernize-use-trailing-return-type]

    use a trailing return type for this function

        void *not_useful(char *str){useless = str;}
        ~~~~~~^
        auto                        -> void *

Have any feedback or feature suggestions? Share it here.

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cpp-Linter Report ⚠️

Some files did not pass the configured checks!

clang-format reports: 2 file(s) not formatted
  • demo/demo.cpp
  • demo/demo.hpp
clang-tidy reports: 7 concern(s)
  • demo/demo.cpp

    /demo/demo.cpp:3:10: error: [clang-diagnostic-error]

    'stdio.h' file not found

    #include <stdio.h>
             ^

    /demo/demo.cpp:3:10: warning: [modernize-deprecated-headers]

    inclusion of deprecated C++ header 'stdio.h'; consider using 'cstdio' instead

    #include <stdio.h>
             ^~~~~~~~~
             <cstdio>

    /demo/demo.cpp:8:5: warning: [modernize-use-trailing-return-type]

    use a trailing return type for this function

    int main(){
    ~~~ ^
    auto       -> int

    /demo/demo.cpp:10:13: warning: [readability-braces-around-statements]

    statement should be inside braces

        for (;;) break;
                ^
                 {
  • demo/demo.hpp

    /demo/demo.hpp:6:11: warning: [modernize-use-default-member-init]

    use default member initializer for 'useless'

        char* useless;
              ^
                     {"\0"}

    /demo/demo.hpp:7:9: warning: [modernize-use-default-member-init]

    use default member initializer for 'numb'

        int numb;
            ^
                {0}

    /demo/demo.hpp:11:11: warning: [modernize-use-trailing-return-type]

    use a trailing return type for this function

        void *not_useful(char *str){useless = str;}
        ~~~~~~^
        auto                        -> void *

Have any feedback or feature suggestions? Share it here.

Please sign in to comment.