gradle에서 war파일 생성 시, 특정 리소스 제외하기

catch me if u can!·2021년 3월 10일
0

build.gradle 파일에서 sourceSets.main.resources 세션에 exclude를 추가한다. 아래 설정(exclude "**/static/pub/**")은 src/main/resources/static/pub 폴더를 war파일 생성 시 제외한다.

sourceSets {
  ...
  main {
    java { ... }
    resources {
      srcDirs "src/main/resources"
      exclude "**/static/pub/**"
    }
  }
}
profile
마쿠투소케 난쿠로나이사

0개의 댓글