Commit 7d8bd178 by Jessica Hawkwell

got something to build

1 parent 41c74973
Pipeline #199 passed
in 1 minute 33 seconds
......@@ -116,6 +116,11 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/ma
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>me.felinewith.lang-toolkit.library</groupId>
<artifactId>liblangbuilder</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-configuration2</artifactId>
<version>2.1.1</version>
......@@ -135,6 +140,18 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/ma
<build>
<defaultGoal>test package install</defaultGoal>
<resources>
<resource>
<directory>src/main/resources</directory>
</resource>
<resource>
<directory>.</directory>
<targetPath>DEPS</targetPath>
<includes>
<include>pom.xml</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
......@@ -143,6 +160,17 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/ma
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
<classpathLayoutType>repository</classpathLayoutType>
<mainClass>me.felinewith.lang_toolkit.apps.bootstrap.Bootstrap</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
......@@ -160,10 +188,17 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/ma
<configuration>
<artifactSet>
<includes>
<include>me.felinewith.lang-toolkit.apps:*</include>
<include>me.felinewith.lang-toolkit.library:*</include>
<include>me.felinewith.lang-toolkit.apps:bootstrap</include>
</includes>
</artifactSet>
<filters>
<filter>
<artifact>me.felinewith.lang-toolkit.apps:bootstrap</artifact>
<excludes>
<exclude>DEPS/*</exclude>
</excludes>
</filter>
</filters>
</configuration>
</execution>
</executions>
......
package email.tadpole;
import java.io.File;
import me.felinewith.lang_toolkit.library.IStrappedApp;
import me.felinewith.lang_toolkit.library.IStrappedPlugin;
import me.felinewith.lang_toolkit.library.helpers.ConfigHelper;
import org.apache.commons.configuration2.Configuration;
import org.apache.commons.configuration2.XMLConfiguration;
import org.apache.commons.configuration2.builder.FileBasedConfigurationBuilder;
import org.apache.commons.configuration2.builder.fluent.Parameters;
import org.apache.commons.configuration2.ex.ConfigurationException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
/**
*
......@@ -10,16 +18,49 @@ import org.apache.commons.configuration2.Configuration;
*/
public class TadpoleMail implements IStrappedApp {
private Logger log;
Configuration config;
@Override public void preStart(String[] args) {
log = LogManager.getLogger();
StringBuilder sb = new StringBuilder(System.getProperty("user.home"));
sb.append("/.local/share/tadpole/mail.xml");
File f = new File(sb.toString());
if ( !f.getParentFile().exists() ) { f.getParentFile().mkdirs(); }
Parameters params = new Parameters();
params.xml().setThrowExceptionOnMissing(false);
params.xml().setFileName(sb.toString());
params.xml().setEncoding("UTF-8");
params.xml().setValidating(false);
FileBasedConfigurationBuilder<XMLConfiguration> builder =
new FileBasedConfigurationBuilder<>(XMLConfiguration.class);
builder.configure(params.xml());
if ( f.exists() ) {
if ( !builder.getFileHandler().isLocationDefined() )
{ builder.getFileHandler().setFileName(sb.toString()); }
}
builder.getFileHandler().setEncoding("UTF-8");
config = null;
try {
config = new ConfigHelper(builder.getConfiguration(), builder);
}
catch ( ConfigurationException x ) { log.fatal("Config setup FAILED!"); }
}
@Override public Configuration getConfig() {
return null;
return config;
}
@Override public void registerPlugin(IStrappedPlugin plugin) {
}
@Override public void start() {
log.info("We got so far...");
}
}
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/DECORATION/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/DECORATION/1.0.0 http://maven.apache.org/xsd/decoration-1.0.0.xsd">
<skin>
<groupId>org.apache.maven.skins</groupId>
<artifactId>maven-fluido-skin</artifactId>
<version>1.6</version>
</skin>
<custom>
<fluidoSkin>
<sideBarEnabled>true</sideBarEnabled>
<topBarEnabled>true</topBarEnabled>
<navBarStyle>navbar-inverse</navBarStyle>
<copyrightClass>pull-right</copyrightClass>
<breadcrumbDivider>&raquo;</breadcrumbDivider>
<sourceLineNumbersEnabled>true</sourceLineNumbersEnabled>
</fluidoSkin>
</custom>
<version position="right" />
<publishDate position="right" format="yyyy-MM-dd'T'HH:mm:ssZ" />
<!-- poweredBy>
<logo name="VOCASystem.Net" href="https://dev.vocasystem.net/" alt="VOCASystem.Net"
img="http://static.vocasystem.net/vocasystem.net/images/vocasystem.net-black.png" />
</poweredBy -->
<body>
<breadcrumbs>
<item name="${this.name}" href="${this.url}" />
</breadcrumbs>
<menu ref="parent" inherit="top" />
<menu ref="modules" inherit="bottom" />
<menu name="Project Information" ref="reports" inherit="bottom" />
</body>
</project>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!