FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
Java/.github/workflows/checkstyle.yml at dev · primary-code-test/Java · GitHub
primary-code-test
Java
Repository navigation
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
Java
/
.github
/
workflows
/
checkstyle.yml
Copy path
View runs
More file actions
More file actions
Latest commit
History
History
History
24 lines (23 loc) · 1020 Bytes
Breadcrumbs
Java
/
.github
/
workflows
/
checkstyle.yml
Copy path
File metadata and controls
24 lines (23 loc) · 1020 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
name
:
Code Formatter
on
:
[push, pull_request]
jobs
:
format
:
runs-on
:
ubuntu-latest
steps
:
-
uses
:
actions/checkout@master
-
uses
:
actions/setup-python@v2
-
name
:
Set up JDK 12
uses
:
actions/setup-java@v1
with
:
java-version
:
12
-
run
:
wget https://github.com/google/google-java-format/releases/download/google-java-format-1.9/google-java-format-1.9-all-deps.jar -O formatter.jar
-
run
:
java -jar formatter.jar --replace --set-exit-if-changed $(find . -type f -name "*.java")
-
name
:
Commit Format changes
if
:
failure()
run
:
|
git diff
git config --global user.name github-actions
git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com'
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY
git commit -am "Formatted with Google Java Formatter" ||
true
git push --force origin HEAD:$GITHUB_REF ||
true
Back
|
FazBrowse Home
|
New Git URL