modify pom and use resource filtering...

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

10
pom.xml
View File

@ -1,12 +1,18 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" <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"> 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> <modelVersion>4.0.0</modelVersion>
<groupId>cn.CityCraft</groupId> <groupId>cn.citycraft</groupId>
<artifactId>Yum</artifactId> <artifactId>Yum</artifactId>
<version>1.1</version> <version>1.3</version>
<name>Yum</name> <name>Yum</name>
<build> <build>
<finalName>${project.name}</finalName> <finalName>${project.name}</finalName>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
<plugins> <plugins>
<plugin> <plugin>
<artifactId>maven-compiler-plugin</artifactId> <artifactId>maven-compiler-plugin</artifactId>

View File

@ -112,7 +112,12 @@ public class DownloadManager {
public boolean update(CommandSender sender, Plugin plugin) { public boolean update(CommandSender sender, Plugin plugin) {
String pluginname = plugin.getName(); String pluginname = plugin.getName();
String filename = PluginsManager.getPluginFile(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) { public boolean yum(CommandSender sender, String pluginname) {

View File

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