git-svn-id: https://svn.apache.org/repos/asf/incubator/felix/trunk@360422 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/tools/maven2/osgi-archetype/pom.xml b/tools/maven2/osgi-archetype/pom.xml
new file mode 100644
index 0000000..1bf47a3
--- /dev/null
+++ b/tools/maven2/osgi-archetype/pom.xml
@@ -0,0 +1,8 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

+  <modelVersion>4.0.0</modelVersion>

+  <groupId>org.apache.felix.archetypes</groupId>

+  <artifactId>osgi-archetype</artifactId>

+  <packaging>maven-plugin</packaging>

+  <version>1.0</version>

+</project>

diff --git a/tools/maven2/osgi-archetype/src/main/resources/META-INF/archetype.xml b/tools/maven2/osgi-archetype/src/main/resources/META-INF/archetype.xml
new file mode 100644
index 0000000..9c3c115
--- /dev/null
+++ b/tools/maven2/osgi-archetype/src/main/resources/META-INF/archetype.xml
@@ -0,0 +1,6 @@
+<archetype>

+  <id>osgi-archetype</id>

+  <sources>

+    <source>src/main/java/MyBundleActivator.java</source>

+  </sources>

+</archetype>
\ No newline at end of file
diff --git a/tools/maven2/osgi-archetype/src/main/resources/archetype-resources/pom.xml b/tools/maven2/osgi-archetype/src/main/resources/archetype-resources/pom.xml
new file mode 100644
index 0000000..b36f583
--- /dev/null
+++ b/tools/maven2/osgi-archetype/src/main/resources/archetype-resources/pom.xml
@@ -0,0 +1,54 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

+  <modelVersion>4.0.0</modelVersion>

+  <groupId>${groupId}</groupId>

+  <artifactId>${artifactId}</artifactId>

+  <packaging>osgi-bundle</packaging>

+  <version>${version}</version>

+  <name>My Bundle Project Name Here</name>

+  <url>My Organization URL Here</url>

+  <build>

+    <!--

+    ***********************************************************

+    * Uncomment out to override default jar naming convention *

+    ***********************************************************

+    <finalName>my-bundle</finalName>

+    -->

+    <plugins>

+      <plugin>

+        <groupId>org.apache.felix.plugins</groupId>

+        <artifactId>maven-osgi-plugin</artifactId>

+        <extensions>true</extensions>

+        <version>0.3.0</version>

+        <configuration>

+          <!--

+          *************************************************

+          * Uncomment to specify a manifest file to merge *

+          *************************************************

+          <manifestFile>path/to/manifest.mf</manifestFile>

+          -->

+

+          <!--

+          *******************************************************************

+          * See the following link for entry specification                  *

+          * http://docs.safehaus.org/display/OSGI/OSGi+Plugin+for+Maven+2.0 *

+          *******************************************************************

+          -->

+          <osgiManifest>

+            <bundleName>My Bundle Name</bundleName>

+            <bundleActivator>${groupId}.MyBundleActivator</bundleActivator>

+            <bundleVendor>My Organization Name</bundleVendor>

+          </osgiManifest>

+        </configuration>

+      </plugin>

+    </plugins>

+  </build>

+  <dependencies>

+    <dependency>

+      <groupId>org.osgi</groupId>

+      <artifactId>org.osgi</artifactId>

+      <version>3.0</version>

+      <scope>provided</scope>

+    </dependency>

+  </dependencies>

+</project>
\ No newline at end of file
diff --git a/tools/maven2/osgi-archetype/src/main/resources/archetype-resources/src/main/java/MyBundleActivator.java b/tools/maven2/osgi-archetype/src/main/resources/archetype-resources/src/main/java/MyBundleActivator.java
new file mode 100644
index 0000000..df7ed40
--- /dev/null
+++ b/tools/maven2/osgi-archetype/src/main/resources/archetype-resources/src/main/java/MyBundleActivator.java
@@ -0,0 +1,33 @@
+/*

+ *   Copyright 2004 The Apache Software Foundation

+ *

+ *   Licensed under the Apache License, Version 2.0 (the "License");

+ *   you may not use this file except in compliance with the License.

+ *   You may obtain a copy of the License at

+ *

+ *       http://www.apache.org/licenses/LICENSE-2.0

+ *

+ *   Unless required by applicable law or agreed to in writing, software

+ *   distributed under the License is distributed on an "AS IS" BASIS,

+ *   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

+ *   See the License for the specific language governing permissions and

+ *   limitations under the License.

+ *

+ */

+package ${groupId};

+

+import org.osgi.framework.BundleActivator;

+import org.osgi.framework.BundleContext;

+

+public class MyBundleActivator implements BundleActivator {

+

+    public void start(BundleContext bundleContext) throws Exception {

+        // Put code here to initialize your bundle...

+        System.out.println("Bundle started.");

+    }

+

+    public void stop(BundleContext bundleContext) throws Exception {

+        // Put code here to finalize your bundle...

+        System.out.println("Bundle stopped.");

+    }

+}