Skip to content

Instantly share code, notes, and snippets.

Luca lucatk

Block or report user

Report or block lucatk

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
lucatk /
Last active Aug 29, 2015
Class for serializing Locations (Bukkit)
import java.util.HashMap;
import java.util.Map;
import org.bukkit.Bukkit;
import org.bukkit.Location;
import org.bukkit.World;
import org.bukkit.configuration.serialization.ConfigurationSerializable;
import org.bukkit.util.NumberConversions;
public class LocationSerializable extends Location implements ConfigurationSerializable {
lucatk /
Created Aug 31, 2014
Save resource file to specific folder
public boolean saveResourceToPath(String resourcePath, String targetFolder) {
InputStream in = getResource(resourcePath);
if(in == null)
return false;
int lastIndex = resourcePath.lastIndexOf('/');
File outDir = new File(dataFolder, resourcePath.substring(0, lastIndex >= 0 ? lastIndex : 0));
File outFile = new File(targetFolder, resourcePath)
lucatk / imagemagick.rb
Last active Feb 8, 2017 — forked from asanchez75/ImageMagick 6.9.7-4 Homebrew
Homebrew Formula for ImageMagick 6.9.7-7
View imagemagick.rb
require 'formula'
class Imagemagick < Formula
homepage ''
url ''
sha256 'c0454629e7d3cbced6df31c2c3b6cbfbe8088437e511c1e3a70de2f18d4e6694'
head '',
:using => UnsafeSubversionDownloadStrategy
You can’t perform that action at this time.