Skip to content

Commit

Permalink
cleanup, switched to maven
Browse files Browse the repository at this point in the history
  • Loading branch information
EtienneDx committed Apr 28, 2019
1 parent 9578ebb commit 277fc4a
Show file tree
Hide file tree
Showing 15 changed files with 500 additions and 330 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.classpath
.project
.settings/*
bin/*
bin/*
target/*
2 changes: 1 addition & 1 deletion plugin.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: RealEstate
main: me.EtienneDx.RealEstate.RealEstate
version: beta0.1
version: ${project.version}
authors: [EtienneDx]
depend: [GriefPrevention, Vault]

Expand Down
69 changes: 69 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
<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>Me.EtienneDx</groupId>
<artifactId>RealEstate</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>RealEstate</name>
<description>A spigot plugin for selling, renting and leasing GriefPrevention claims</description>
<build>
<sourceDirectory>src</sourceDirectory>
<resources>
<resource>
<directory>.</directory>
<filtering>true</filtering>
<targetPath>.</targetPath>
<includes>
<include>plugin.yml</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>spigot-repo</id>
<url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url>
</repository>
<repository>
<id>bungeecord-repo</id>
<url>https://()oss.sonatype.org/content/repositories/snapshots</url>
</repository>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
<repository>
<id>vault-repo</id>
<url>http://nexus.hc.to/content/repositories/pub_releases</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>org.spigotmc</groupId>
<artifactId>spigot-api</artifactId>
<version>1.13.2-R0.1-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>net.milkbowl.vault</groupId>
<artifactId>VaultAPI</artifactId>
<version>1.7</version>
</dependency>
<dependency>
<groupId>com.github.TechFortress</groupId>
<artifactId>GriefPrevention</artifactId>
<version>16.11.6</version>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import org.bukkit.configuration.file.YamlConfiguration;
import org.bukkit.plugin.PluginDescriptionFile;

public class DataStore
public class Config
{
public PluginDescriptionFile pdf;

Expand All @@ -34,6 +34,7 @@ public class DataStore
public boolean cfgEnableLease;

public boolean cfgEnableAutoRenew;
public boolean cfgEnableRentPeriod;

public boolean cfgTransferClaimBlocks;

Expand All @@ -50,7 +51,7 @@ public class DataStore

public int cfgLeasePayments;

public DataStore()
public Config()
{
this.pdf = RealEstate.instance.getDescription();
}
Expand Down Expand Up @@ -91,6 +92,7 @@ public void loadConfig(YamlConfiguration config)
this.cfgEnableLease = config.getBoolean("RealEstate.Rules.Lease", true);

this.cfgEnableAutoRenew = config.getBoolean("RealEstate.Rules.AutomaticRenew", true);
this.cfgEnableRentPeriod = config.getBoolean("RealEstate.Rules.RentPeriods", true);

this.cfgTransferClaimBlocks = config.getBoolean("RealEstate.Rules.TransferClaimBlocks", true);

Expand Down Expand Up @@ -133,6 +135,7 @@ public void saveConfig()
outConfig.set("RealEstate.Rules.Lease", this.cfgEnableLease);

outConfig.set("RealEstate.Rules.AutomaticRenew", this.cfgEnableAutoRenew);
outConfig.set("RealEstate.Rules.RentPeriods", this.cfgEnableRentPeriod);

outConfig.set("RealEstate.Rules.TransferClaimBlocks", this.cfgTransferClaimBlocks);

Expand Down
Loading

0 comments on commit 277fc4a

Please sign in to comment.