-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #43 from Nookure/dev
Release 2.4.0
- Loading branch information
Showing
312 changed files
with
9,789 additions
and
8,587 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,28 @@ | ||
name: Publish to nexus | ||
|
||
on: [push] | ||
on: [ push ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- name: Set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 11 | ||
- name: Grant perms to gradlew | ||
run: chmod +x ./gradlew | ||
- name: build | ||
run: ./gradlew shadowJar | ||
- name: Nexus Repo Publish | ||
uses: sonatype-nexus-community/nexus-repo-github-action@master | ||
with: | ||
serverUrl: https://repo.nookure.com/ | ||
username: admin | ||
password: ${{ secrets.NEXUS_PASSWORD }} | ||
format: maven2 | ||
repository: maven-releases | ||
coordinates: groupId=es.angelillo15 artifactId=mast-api version=2.0.0b | ||
assets: extension=jar | ||
filename: ./MAStaff-API/build/libs/MAStaff-API.jar | ||
- uses: actions/checkout@v1 | ||
- name: Set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 11 | ||
- name: Grant perms to gradlew | ||
run: chmod +x ./gradlew | ||
- name: build | ||
run: ./gradlew shadowJar | ||
- name: Nexus Repo Publish | ||
uses: sonatype-nexus-community/nexus-repo-github-action@master | ||
with: | ||
serverUrl: https://repo.nookure.com/ | ||
username: admin | ||
password: ${{ secrets.NEXUS_PASSWORD }} | ||
format: maven2 | ||
repository: maven-releases | ||
coordinates: groupId=es.angelillo15 artifactId=mast-api version=2.0.0b | ||
assets: extension=jar | ||
filename: ./MAStaff-API/build/libs/MAStaff-API.jar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 10 additions & 13 deletions
23
MAStaff-API/src/main/java/es/angelillo15/mast/api/Constants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,15 @@ | ||
package es.angelillo15.mast.api; | ||
|
||
import lombok.Getter; | ||
|
||
public class Constants { | ||
public static final String VERSION = "{version}"; | ||
public static final String COMMIT = "{git-commit}"; | ||
public static final String COMMIT_USER = "{git-user}"; | ||
public static final String COMMIT_TIME = "{git-date}"; | ||
public static final String GIT_BRANCH = "{git-branch}"; | ||
public static final boolean DEV_MODE = false; | ||
public static String getVersion() { | ||
return VERSION; | ||
} | ||
private Constants() {} | ||
|
||
|
||
public static final String VERSION = "{version}"; | ||
public static final String COMMIT = "{git-commit}"; | ||
public static final String COMMIT_USER = "{git-user}"; | ||
public static final String COMMIT_TIME = "{git-date}"; | ||
public static final String GIT_BRANCH = "{git-branch}"; | ||
public static final boolean DEV_MODE = false; | ||
private Constants() {} | ||
public static String getVersion() { | ||
return VERSION; | ||
} | ||
} |
60 changes: 30 additions & 30 deletions
60
MAStaff-API/src/main/java/es/angelillo15/mast/api/ILogger.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,46 @@ | ||
package es.angelillo15.mast.api; | ||
|
||
public abstract class ILogger { | ||
private static ILogger instance; | ||
private static ILogger instance; | ||
|
||
public static ILogger getInstance() { | ||
return instance; | ||
} | ||
|
||
public static void setInstance(ILogger instance) { | ||
ILogger.instance = instance; | ||
} | ||
public static ILogger getInstance() { | ||
return instance; | ||
} | ||
|
||
abstract public void info(String message); | ||
public static void setInstance(ILogger instance) { | ||
ILogger.instance = instance; | ||
} | ||
|
||
abstract public void warn(String message); | ||
public abstract void info(String message); | ||
|
||
abstract public void error(String message); | ||
public abstract void warn(String message); | ||
|
||
abstract public void debug(String message); | ||
public abstract void error(String message); | ||
|
||
void info(String message, Object... args) { | ||
info(format(message, args)); | ||
} | ||
public abstract void debug(String message); | ||
|
||
void warn(String message, Object... args) { | ||
warn(format(message, args)); | ||
} | ||
void info(String message, Object... args) { | ||
info(format(message, args)); | ||
} | ||
|
||
void error(String message, Object... args) { | ||
error(format(message, args)); | ||
} | ||
void warn(String message, Object... args) { | ||
warn(format(message, args)); | ||
} | ||
|
||
void debug(String message, Object... args) { | ||
debug(format(message, args)); | ||
} | ||
void error(String message, Object... args) { | ||
error(format(message, args)); | ||
} | ||
|
||
String format(String message, Object... args) { | ||
String msg = message; | ||
for (Object arg : args) { | ||
msg = msg.replaceFirst("\\{\\}", arg.toString()); | ||
} | ||
void debug(String message, Object... args) { | ||
debug(format(message, args)); | ||
} | ||
|
||
return msg; | ||
String format(String message, Object... args) { | ||
String msg = message; | ||
for (Object arg : args) { | ||
msg = msg.replaceFirst("\\{\\}", arg.toString()); | ||
} | ||
|
||
return msg; | ||
} | ||
} |
Oops, something went wrong.