Skip to content

Commit 567dd1f

Browse files
authored
Create java-ci.yml
1 parent ad0a8b1 commit 567dd1f

1 file changed

Lines changed: 27 additions & 0 deletions

File tree

.github/workflows/java-ci.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Java CI (compile)
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
- name: Set up JDK 11
15+
uses: actions/setup-java@v4
16+
with:
17+
distribution: temurin
18+
java-version: "11" # 네 환경에 맞춤 (JavaSE-11)
19+
- name: Compile all .java files
20+
run: |
21+
mkdir -p out
22+
files="$(git ls-files '*.java')"
23+
if [ -n "$files" ]; then
24+
javac -d out $files
25+
else
26+
echo "No Java sources found."
27+
fi

0 commit comments

Comments
 (0)