...
It will then prompt you to pick the archetype - choose the latest Tapestry 5.X 3 Quickstart Project, enter the group id, artifact id, version and package when prompted.
No Format |
---|
~/Documents/workspace $ mvn archetype:generate -DarchetypeCatalog=http://tapestry.apache.org [INFO] Scanning for projects... [INFO] Searching repository for plugin with prefix: 'archetype'. [INFO] ------------------------------------------------------------------------ [INFO] Building Maven DefaultStub Project [INFO] (No task-segment: [archetype:generate] (aggregator-style)POM) 1 [INFO] ------------------------------------------------------------------------ [INFO] [INFO] Preparing>>> maven-archetype-plugin:2.1:generate (default-cli) @ standalone-pom >>> [INFO] No goals needed for project - skipping [INFO] <<< maven-archetype-plugin:2.1:generate (default-cli) @ standalone-pom <<< [INFO] [INFO] --- maven-archetype-plugin:2.1:generate {execution: (default-cli}]) @ standalone-pom --- [INFO] Generating project in Interactive mode [INFO] No archetype defined. Using maven-archetype-quickstart (org.apache.maven.archetypes:maven-archetype-quickstart:1.0) Choose archetype: 1: http://tapestry.apache.org -> org.apache.tapestry:quickstart (Tapestry 5.X Quickstart Project) 2: http://tapestry.apache.org -> org.apache.tapestry:tapestry-archetype (Tapestry 4.1.6 Archetype) Choose a number or apply filter (format: [groupId:]artifactId, case sensitive contains): : 1 Choose version: 1: 5.1.0.519 2: 5.1.0.195 3: 5.2.46 4: 5.2.53 Choose a number: 4: 4 Define value for property 'groupId': : com.example Define value for property 'artifactId': : tutorial1 Define value for property 'version': 1.0-SNAPSHOT: : Define value for property 'package': com.example: : com.example.tutorial Confirm properties configuration: groupId: com.example artifactId: tutorial1 version: 1.0-SNAPSHOT package: com.example.tutorial Y: : [INFO] ---------------------------------------------------------------------------- [INFO] BUILD SUCCESSFUL Using following parameters for creating project from Archetype: quickstart:5.3 [INFO] ---------------------------------------------------------------------------- [INFO] Total time: 1 minute 41 secondsParameter: groupId, Value: com.example [INFO] Parameter: artifactId, Value: tutorial1 [INFO] Parameter: version, Value: 1.0-SNAPSHOT [INFO] Parameter: package, Value: com.example.tutorial [INFO] Parameter: packageInPathFormat, Value: com/example/tutorial [INFO] Parameter: package, Value: com.example.tutorial [INFO] Parameter: version, Value: 1.0-SNAPSHOT [INFO] Parameter: groupId, Value: com.example [INFO] Parameter: artifactId, Value: tutorial1 [WARNING] Don't override file /Users/hlship/Documents/workspace/tutorial1/src/test/java [WARNING] Don't override file /Users/hlship/Documents/workspace/tutorial1/src/main/webapp [WARNING] Don't override file /Users/hlship/Documents/workspace/tutorial1/src/main/resources/com/example/tutorial [WARNING] Don't override file /Users/hlship/Documents/workspace/tutorial1/src/test/resources [WARNING] Don't override file /Users/hlship/Documents/workspace/tutorial1/src/test/conf [WARNING] Don't override file /Users/hlship/Documents/workspace/tutorial1/src/site [INFO] project created from Archetype in dir: /Users/hlship/Documents/workspace/tutorial1 [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 22.398s [INFO] Finished at: WedTue JulNov 0222 1711:0046:1608 PST 2011 [INFO] Final Memory: 16M7M/81M [INFO] ------------------------------------------------------------------------ ~/Documents/workspace $ |
...
Once Jetty is initialized (which only takes a few seconds), you'll see the following in your console:
No Format |
---|
TranslatorSource: DEFINED TypeCoercer: REAL URLRewriterURLEncoder: DEFINED UpdateListenerHub: REALDEFINED ValidateBindingFactory: DEFINED ValidationConstraintGenerator: DEFINED ValidationMessagesSourceValidationDecoratorFactory: DEFINED ValidatorMacro: DEFINED ValueEncoderSource: DEFINED 8586.00%77% unrealized services (153/180) 2010-11-17 17:06:30.630164/189) Application 'app' (version 1.0-SNAPSHOT-DEV) startup time: 137 ms to build IoC Registry, 705 ms overall. ______ __ ____ /_ __/__ ____ ___ ___ / /_______ __ / __/ / / / _ `/ _ \/ -_|_-</ __/ __/ // / /__ \ /_/ \_,_/ .__/\__/___/\__/_/ \_, / /____/ /_/ /___/ 5.3 (development mode) 2011-11-22 11:46:45.636::INFO: Started SelectChannelConnector@0.0.0.0:8080 [INFO] Started Jetty Server |
You can now open a web browser to http://localhost:8080/tutorial1/ to see the running application:
The date and time in the middle of the page proves that this is a live application.
This is a complete little application; it doesn't do much, but it demonstrate how to create a number of pages sharing a common layout, and demonstrates some simple navigation and link hanlding. You can see that it has three different pages that share a common layout
Footnote |
---|
Layout is a loose term meaning common look and feel and navigation across many or all of the pages of an application. Often an application will include a Layout component to provide that commonness. |
...