modify pom and use resource filtering...

Signed-off-by: 502647092 <jtb1@163.com>
dev
502647092 2015-08-24 12:26:41 +08:00
parent 153cb6d88d
commit 323b65f5c4
3 changed files with 32 additions and 20 deletions

36
pom.xml
View File

@ -1,23 +1,29 @@
<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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>cn.CityCraft</groupId>
<groupId>cn.citycraft</groupId>
<artifactId>Yum</artifactId>
<version>1.1</version>
<version>1.3</version>
<name>Yum</name>
<build>
<finalName>${project.name}</finalName>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
</plugins>
</build>
<build>
<finalName>${project.name}</finalName>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>spigot-repo</id>

View File

@ -112,7 +112,12 @@ public class DownloadManager {
public boolean update(CommandSender sender, Plugin plugin) {
String pluginname = plugin.getName();
String filename = PluginsManager.getPluginFile(plugin).getName();
return run(sender, getUrl(pluginname), new File("plugins/update", filename));
URL url = getUrl(pluginname);
if (url == null) {
sender.sendMessage("§4错误: §cURL地址解析失败!");
return false;
}
return run(sender, url, new File("plugins/update", filename));
}
public boolean yum(CommandSender sender, String pluginname) {

View File

@ -1,7 +1,8 @@
name: Yum
main: cn.citycraft.Yum.Yum
website: http://ci.citycraft.cn:8800/jenkins/job/Yum/
version: 1.3
name: ${project.artifactId}
main: ${project.groupId}.${project.artifactId}.${project.artifactId}
website: http://ci.citycraft.cn:8800/jenkins/job/${project.artifactId}/
version: ${project.version}
commands:
yum:
description: MC插件仓库