I am trying to run the samples from http://projects.spring.io/spring-security/
this guide explains how to run the insecuremvc sample from Spring Tool Suite (STS): http://docs.spring.io/spring-security/site/docs/3.2.x/guides/hellomvc.html
How can I run the sample from the command line (instead of from STS)?
I've tried adding the following to pom.xml -> project/build/plugins:
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<path>/</path>
<uriEncoding>UTF-8</uriEncoding>
<hostName>localhost</hostName>
<port>8080</port>
<update>true</update>
<useTestClasspath>true</useTestClasspath>
</configuration>
</plugin>
and running
$ mvn package tomcat7:run
but browsing http://localhost:8080/sample/
I get a HTTP Status 400 - The request sent by the client was syntactically incorrect.
Solution based on Luke's answer
$ git clone https://github.com/spring-projects/spring-security.git
$ cd spring-security/samples/insecuremvc
$ ../../gradlew tasks
# this shows several defined tasks, tomcatRunWar among them
$ ../../gradlew tomcatRunWar