Skip to content

Instantly share code, notes, and snippets.

@TimWolla
Created May 15, 2011 08:28
Show Gist options
  • Select an option

  • Save TimWolla/972972 to your computer and use it in GitHub Desktop.

Select an option

Save TimWolla/972972 to your computer and use it in GitHub Desktop.
package de.evilco.example;
import java.util.logging.*;
import org.bukkit.plugin.PluginDescriptionFile;
import org.bukkit.plugin.java.JavaPlugin;
public class Example extends JavaPlugin {
public void onEnable() {
PluginDescriptionFile pdfFile = this.getDescription();
Logger.getLogger(pdfFile.getName()).log(Level.INFO, pdfFile.getName() + " version " + pdfFile.getVersion() + " enabled");
}
public void onDisable() {
Logger.getLogger(this.getDescription().getName()).log(Level.INFO, "Unloading");
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment