Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
caseif committed Dec 28, 2016
2 parents d1bd973 + 5c8bc8d commit 6f60991
Show file tree
Hide file tree
Showing 65 changed files with 2,580 additions and 576 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ script: ./gradlew build
notifications:
email: false

before_install:
- git config --global user.name "Lapislazuli"
- git config --global user.email "[email protected]"

before_script:
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
Expand Down
29 changes: 29 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
node {
def win = System.properties['os.name'].startsWith('Windows')

stage 'Stage Checkout'
checkout scm
if (win) {
bat 'git submodule update --init'
} else {
sh 'git submodule update --init'
}

stage 'Stage Build'
def ver = version()
echo "Building version ${ver} on branch ${env.BRANCH_NAME}"
if (win) {
bat "./gradlew -PBUILD_NUMBER=${env.BUILD_NUMBER}"
} else {
sh "./gradlew -PBUILD_NUMBER=${env.BUILD_NUMBER}"
}

stage 'Stage Archive'
step([$class: 'ArtifactArchiver', artifacts: 'build/libs/*.jar', excludes: 'build/libs/*-base.jar',
fingerprint: true])
}

def version() {
def matcher = readFile('build.gradle') =~ 'version = \'(.+)\''
matcher ? matcher[0][1] : null
}
8 changes: 4 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ plugins {
id 'idea'
id 'checkstyle'

id 'net.minecrell.gitpatcher' version '0.8'
id 'net.minecrell.gitpatcher' version '0.8.1'

id 'net.minecrell.licenser' version '0.1.5'
id 'net.minecrell.licenser' version '0.2.1'
id 'com.github.johnrengelman.shadow' version '1.2.3'
}

Expand All @@ -16,7 +16,7 @@ defaultTasks 'clean', 'licenseFormat', 'build'
// Project information
allprojects {
group = 'blue.lapis.nocturne'
version = '1.0.5'
version = '1.1.0'

sourceCompatibility = '1.8'
targetCompatibility = '1.8'
Expand Down Expand Up @@ -125,5 +125,5 @@ artifacts {
}

task wrapper(type: Wrapper) {
gradleVersion = '2.12'
gradleVersion = '3.0'
}
2 changes: 1 addition & 1 deletion etc/checkstyle-suppressions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<suppressions>
<suppress checks=".*" files="[\\/]lib[\\/]"/>
<suppress checks="JavadocMethod" files="^src[\\/](main|test)[\\/]java"/>
<suppress checks="Indentation" files="package-info\.java"/>
<suppress checks="Indentation" files=".*"/>
<suppress checks="Fallthrough" files="ConstantPoolProcessor \.java"/>
<suppress checks="AvoidEscapedUnicodeCharacters" files=".*"/>
</suppressions>
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Sun Mar 27 23:56:52 BST 2016
#Tue Aug 16 18:34:06 EDT 2016
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.12-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-3.0-bin.zip
46 changes: 25 additions & 21 deletions gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,30 @@
##
##############################################################################

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
# Attempt to set APP_HOME
# Resolve links: $0 may be a link
PRG="$0"
# Need this for relative symlinks.
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`"/$link"
fi
done
SAVED="`pwd`"
cd "`dirname \"$PRG\"`/" >/dev/null
APP_HOME="`pwd -P`"
cd "$SAVED" >/dev/null

APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"

Expand All @@ -30,6 +48,7 @@ die ( ) {
cygwin=false
msys=false
darwin=false
nonstop=false
case "`uname`" in
CYGWIN* )
cygwin=true
Expand All @@ -40,26 +59,11 @@ case "`uname`" in
MINGW* )
msys=true
;;
NONSTOP* )
nonstop=true
;;
esac

# Attempt to set APP_HOME
# Resolve links: $0 may be a link
PRG="$0"
# Need this for relative symlinks.
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`"/$link"
fi
done
SAVED="`pwd`"
cd "`dirname \"$PRG\"`/" >/dev/null
APP_HOME="`pwd -P`"
cd "$SAVED" >/dev/null

CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar

# Determine the Java command to use to start the JVM.
Expand All @@ -85,7 +89,7 @@ location of your Java installation."
fi

# Increase the maximum file descriptors if we can.
if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
MAX_FD_LIMIT=`ulimit -H -n`
if [ $? -eq 0 ] ; then
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
Expand Down
8 changes: 4 additions & 4 deletions gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal

@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=

set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%

@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=

@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome

Expand Down Expand Up @@ -46,7 +46,7 @@ echo location of your Java installation.
goto fail

:init
@rem Get command-line arguments, handling Windowz variants
@rem Get command-line arguments, handling Windows variants

if not "%OS%" == "Windows_NT" goto win9xME_args
if "%@eval[2+2]" == "4" goto 4NT_args
Expand Down
10 changes: 10 additions & 0 deletions src/main/java/blue/lapis/nocturne/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
import blue.lapis.nocturne.gui.scene.control.WebLink;
import blue.lapis.nocturne.jar.model.ClassSet;
import blue.lapis.nocturne.mapping.MappingContext;
import blue.lapis.nocturne.mapping.io.writer.MappingWriterType;
import blue.lapis.nocturne.util.helper.PropertiesHelper;
import blue.lapis.nocturne.util.helper.SceneHelper;

Expand Down Expand Up @@ -86,6 +87,7 @@ public class Main extends Application {

private final MappingContext mappingContext = new MappingContext();
private Path currentMappingsPath;
private MappingWriterType currentWriterType;
private ClassSet loadedJar;

static {
Expand Down Expand Up @@ -248,6 +250,14 @@ public static void setCurrentMappingsPath(Path path) {
getInstance().currentMappingsPath = path;
}

public static MappingWriterType getCurrentWriterType() {
return getInstance().currentWriterType;
}

public static void setCurrentWriterType(MappingWriterType currentWriterType) {
getInstance().currentWriterType = currentWriterType;
}

public static ClassSet getLoadedJar() {
return getInstance().loadedJar;
}
Expand Down
Loading

0 comments on commit 6f60991

Please sign in to comment.