(Maven 2.2.1)
こんにちは、私はこのdirツリーを持っています:
.
├── pom.xml
├── src
│ ├── main
│ │ └── webapp
│ │ ├── META-INF
│ │ ├── **resources**
│ │ │ ├── **bootstrap**
│ │ │ │ ├── **bootstrap**
│ │ │ │ │ ├── css
│ │ │ │ │ ├── img
│ │ │ │ │ └── js
│ │ │ │ ├── docs
│ │ │ │ ├── img
│ │ │ │ ├── js
│ │ │ │ ├── less
│ │ │ │ ├── LICENSE
│ │ │ │ ├── Makefile
│ │ │ │ ├── package.json
│ │ │ │ └── README.md
│ │ │ ├── cms
│ │ │ └── **static**
│ │ │ ├── css
│ │ │ ├── feeds
│ │ │ ├── img
│ │ │ ├── js
│ │ │ └── less
│ │ ├── WEB-INF
私がdouble*で強調したところ興味深いディレクトリ...
パッケージ時にresources/bootstrap
、最終的なWARから除外することと、内部にコピーすることの両方を試みています。resources/bootstrap/boostrap
resources/static
言い換えれば、私は以下を取得する必要があります:
.
│ │ ├── META-INF
│ │ ├── **resources**
│ │ │ ├── cms
│ │ │ └── **static**
│ │ │ ├── **bootstrap**
│ │ │ │ ├── css
│ │ │ │ ├── img
│ │ │ │ └── js
│ │ │ ├── css
│ │ │ ├── feeds
│ │ │ ├── img
│ │ │ ├── js
│ │ │ └── less
│ │ ├── WEB-INF
不幸にもいじり回っていますmaven-war-plugin
が、それでも目的の結果を得ることができません。
これが私のpomの関連部分の最新バージョンです:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.2</version>
<configuration>
<packagingExcludes>WEB-INF/**.tld</packagingExcludes>
<warSourceExcludes>resources/bootstrap</warSourceExcludes>
<webResources>
<resource>
<!-- this is relative to the pom.xml directory -->
<directory>src/main/webapp/resources/bootstrap</directory>
<!-- override the destination directory for this resource -->
<targetPath>resources/static</targetPath>
<includes>
<include>bootstrap/**</include>
</includes>
</resource>
</webResources>
</configuration>
</plugin>
フォローアップのヒントを事前にありがとう!