YETUS-992. Create and publish a github action
diff --git a/README.md b/README.md index 416466c..c8d144d 100644 --- a/README.md +++ b/README.md
@@ -18,7 +18,8 @@ # Apache Yetus test-patch This action enables Apache Yetus' change testing facilities via GitHub actions -without significant configuration. To use it, add the following work flow: +without significant configuration. For simple usage (with bleeding edge versions), +add the following work flow: ```yaml --- @@ -38,11 +39,12 @@ path: src fetch-depth: 0 - name: Apache Yetus test-patch - uses: apache/yetus-test-patch-action@v1 + uses: apache/yetus-test-patch-action@main with: basedir: ./src patchdir: ./out buildtool: nobuild + githubtoken: ${{ secrets.GITHUB_TOKEN }} - name: Artifact output if: ${{ always() }} uses: actions/upload-artifact@v2 @@ -51,4 +53,5 @@ path: ${{ github.workspace }}/out ``` -For more information, see the [Apache Yetus Website](https://yetus.apache.org). +For more complex usage or just more information in general, see the +[Apache Yetus Website](https://yetus.apache.org/documentation/in-progress/precommit/robots/githubactions/).
diff --git a/action.yml b/action.yml index c98d2f4..916689a 100644 --- a/action.yml +++ b/action.yml
@@ -24,38 +24,54 @@ description: 'Directory location of source' required: true default: "${GITHUB_WORKSPACE}" + blankseolignorefile: + descipription: 'regex list of files to ignore blanks EOL' + default: .yetus/blanks-eol.txt + blankstabsignorefile: + description: 'regex list of files to ignore tabs' + default: .yetus/blanks-tabs.txt + bufbasedir: + description: 'Location where to run buf' + default: . + buildtool: + description: 'Name of build tool plug-in to use' + default: "nobuild" continuousimprovement: description: 'Pass branches that would otherwise fail' default: false - patchdir: - description: 'Directory location of logs, temp space, etc' - required: true - default: "/tmp/yetus" + excludes: + description: 'Filename of files/directories to ignore' + default: '.yetus/excludes.txt' githubtoken: description: 'GitHub token to use' required: true default: '' - buildtool: - description: 'Name of build tool plug-in to use' - default: "nobuild" - excludes: - description: 'Filename of files/directories to ignore' - default: '.yetus-excludes.txt' javahome: description: 'Location of the JDK to use' default: '/usr/lib/jvm/java-11-openjdk-amd64' - plugins: - description: 'Fine grained control over plug-ins' - default: all,-asflicense,-author,-findbugs,-gitlabcilint,-shelldocs - pylint: - description: 'Major Python version to use for pylint: pylint2 or pylint3' - default: pylint3 + patchdir: + description: 'Directory location of logs, temp space, etc' + required: true + default: "/tmp/yetus" pip: description: 'Major Python version to use for pip: pip2 or pip3' default: pip3 + plugins: + description: 'Fine grained control over plug-ins' + default: all,-asflicense,-author,-findbugs,-golangcilint,-shelldocs + project: + description: 'Name of project to put on reports, default personality, etc' + default: unknown + pylint: + description: 'Major Python version to use for pylint: pylint2 or pylint3' + default: pylint3 reapermode: description: 'How to handle stale surefire tests' default: kill + reviveconfig: + description: 'Configuration file for revive' + default: .revive.toml + runs: using: 'docker' image: docker://apache/yetus:main @@ -63,6 +79,7 @@ - test-patch - --basedir=${{ inputs.basedir }} - --brief-report-file=${{ inputs.patchdir }}/brief.txt + - --buf-basedir=${{ inputs.bufbasedir }} - --build-tool=${{ inputs.buildtool }} - --console-report-file=${{ inputs.patchdir }}/console.txt - --continuous-improvement=${{ inputs.continuousimprovement }} @@ -72,7 +89,11 @@ - --junit-report-xml=${{ inputs.patchdir }}/junit-report.xml - --patch-dir=${{ inputs.patchdir }} - --plugins=${{ inputs.plugins }} + - --project=${{ inputs.project }} - --pylint-pip-cmd=${{ inputs.pip }} - --pylint-requirements=true - --pylint=${{ inputs.pylint }} - --reapermode=${{ inputs.reapermode }} + - --revive-config=${{ inputs.reviveconfig }} + - --blanks-eol-ignore-file=${{ inputs.blankseolignorefile }} + - --blanks-tabs-ignore-file=${{ inputs.blankstabsignorefile }}