Skip to content

Commit

Permalink
prepare repository for modularization
Browse files Browse the repository at this point in the history
  • Loading branch information
astrapi69 committed Sep 21, 2023
1 parent 8e6a2ba commit cd5e142
Show file tree
Hide file tree
Showing 12 changed files with 57 additions and 38 deletions.
35 changes: 16 additions & 19 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,28 +13,25 @@ on:
pull_request:
branches: [ develop ]

permissions:
contents: read

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Build with Gradle
uses: gradle/gradle-build-action@v2.8.0
with:
arguments: build
env:
ossrhUsername: ${{secrets.OSSRHUSERNAME}}
ossrhPassword: ${{secrets.OSSRHPASSWORD}}
- uses: codecov/codecov-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
- name: Build with Gradle
uses: gradle/gradle-build-action@v2.8.0
with:
arguments: build
env:
ossrhUsername: ${{secrets.OSSRHUSERNAME}}
ossrhPassword: ${{secrets.OSSRHPASSWORD}}
- uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
4 changes: 3 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ apply from: "gradle/publishing.gradle"
apply from: "gradle/repositories.gradle"
apply from: "gradle/testing.gradle"

sourceCompatibility = "$projectSourceCompatibility" as Object
java {
sourceCompatibility = "$projectSourceCompatibility" as Object
}

tasks.withType(JavaCompile) {
options.encoding = "UTF-8"
Expand Down
16 changes: 8 additions & 8 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
######################
projectVersion=9.1-SNAPSHOT
groupPackage=io.github.astrapi69
projectSourceCompatibility=11
projectSourceCompatibility=17
projectInceptionYear=2015
projectHolderUsername=astrapi69
projectLeaderName=Asterios Raptis
Expand All @@ -28,28 +28,28 @@ projectRepositoriesPasswordKey=ossrhPassword
###########################
# gradle-plugins versions #
###########################
gradlePluginVersionsVersion=0.47.0
gradlePluginVersionsVersion=0.48.0
licenseGradlePluginVersion=0.16.1
grgitGradlePluginVersion=5.2.0
spotlessGradlePluginVersion=6.20.0
spotlessGradlePluginVersion=6.21.0
#########################
# dependencies versions #
#########################
jobjCoreVersion=7.1
jobjReflectVersion=1
sillyCollectionVersion=21
vintageTimeVersion=5.4
sillyCollectionVersion=27
vintageTimeVersion=6
sillyMathVersion=2.2
jobjCopyVersion=3.7
jobjCopyVersion=4
##############################
# test dependencies versions #
##############################
commonsLang3Version=3.12.0
commonsLang3Version=3.13.0
sillyStringsVersion=8.2
meanbeanVersion=2.0.3
testngVersion=7.8.0
testObjectVersion=7.2
equalsverifierVersion=3.15
equalsverifierVersion=3.15.1
##########################
# for deploy on sonatype #
##########################
Expand Down
4 changes: 3 additions & 1 deletion gradle/formatting.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ spotless {
endWithNewline()
}
java {
eclipse("4.19.0").configFile("src/test/resources/alpharo-formatter.xml")
// export config file: https://github.com/diffplug/spotless/blob/main/ECLIPSE_SCREENSHOTS.md#creating-spotlessimportorder
importOrderFile('src/test/resources/spotless/importorder.properties') // import order file as exported from eclipse
eclipse("4.21").configFile("src/test/resources/spotless/alpharo-formatter.xml")
}
}
4 changes: 3 additions & 1 deletion gradle/publishing.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ task sourcesJar(type: Jar) {
task javadocJar(type: Jar) {
from javadoc
archiveClassifier.set("javadoc")
javadoc.properties.failOnError = true
javadoc {
failOnError = false
}
}

javadoc {
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#Wed Jan 22 15:59:51 CET 2020
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
Expand Down
10 changes: 10 additions & 0 deletions src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
module randomizer.main
{
requires java.desktop;
requires silly.collection;
requires jobj.core.main;
requires jobj.reflect.main;
requires jobj.copy.main;
requires silly.math;
requires vintage.time.main;
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@

import static org.testng.Assert.assertNotNull;

import nl.jqno.equalsverifier.EqualsVerifier;

import org.meanbean.test.BeanTester;
import org.testng.annotations.Test;

import nl.jqno.equalsverifier.EqualsVerifier;

/**
* The unit test class for the class {@link SecureRandomBean}
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@
*/
package io.github.astrapi69.random.object;

import static org.testng.AssertJUnit.assertNotNull;

import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;

import io.github.astrapi69.test.object.A;
import io.github.astrapi69.test.object.AlgorithmModel;
Expand All @@ -48,9 +51,6 @@
import io.github.astrapi69.test.object.auth.Role;
import io.github.astrapi69.test.object.auth.Roles;
import io.github.astrapi69.test.object.exception.ExceptionEvent;
import org.testng.annotations.Test;

import static org.testng.AssertJUnit.assertNotNull;

/**
* The unit test class for the class {@link RandomObjectFactory}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@
import java.util.Set;
import java.util.UUID;

import io.github.astrapi69.test.object.Employee;
import io.github.astrapi69.test.object.EmployeeList;
import org.apache.commons.lang3.ArrayUtils;
import org.meanbean.test.BeanTester;
import org.testng.annotations.Test;

import io.github.astrapi69.collection.list.ListFactory;
import io.github.astrapi69.math.MathExtensions;
import io.github.astrapi69.random.enums.RandomAlgorithm;
import io.github.astrapi69.test.object.Employee;
import io.github.astrapi69.test.object.EmployeeList;
import io.github.astrapi69.test.object.Person;
import io.github.astrapi69.test.object.PrimitiveArrays;
import io.github.astrapi69.test.object.enumtype.Gender;
Expand Down
File renamed without changes.
6 changes: 6 additions & 0 deletions src/test/resources/spotless/importorder.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#Organize Import Order
#Fri Dec 02 17:15:08 CET 2022
0=java
1=javax
2=org
3=com

0 comments on commit cd5e142

Please sign in to comment.