diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d9d2b87..12009ab 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,6 +18,9 @@ on: default: false type: boolean + # Manual Trigger + workflow_dispatch: + env: MODULE_ID: ${{ github.event.repository.name }} JDK: 21 @@ -61,9 +64,16 @@ jobs: id: current_version run: | # Read Version from gradle.properties - echo "VERSION=`grep '^version=' gradle.properties | cut -d'=' -f2`" >> $GITHUB_ENV + TMPVERSION=$(grep '^version=' gradle.properties | cut -d'=' -f2) + # Replace existing prerelease identifier with -snapshot or append -snapshot if none exists + # If we are on the development branch, we always append -snapshot + if [[ "${{ github.ref }}" == "refs/heads/development" ]]; then + TMPVERSION=$(echo $TMPVERSION | sed 's/-.*$//')-snapshot + fi + # Set the version in the environment + echo "VERSION=$TMPVERSION" >> $GITHUB_ENV - # Branche + # Branch echo "Github Ref is $GITHUB_REF" echo "BRANCH=main" >> $GITHUB_ENV @@ -200,12 +210,7 @@ jobs: - name: Bump Version run: | - if [ $LTS == 'true' ] - then - gradle bumpPatchVersion --stacktrace --console=plain - else - gradle bumpMinorVersion --stacktrace --console=plain - fi + gradle bumpMinorVersion --stacktrace --console=plain git pull - name: Commit Version Bump diff --git a/build.gradle b/build.gradle index 043f3d6..992f044 100644 --- a/build.gradle +++ b/build.gradle @@ -22,6 +22,12 @@ ext { buildID = System.getenv( 'BUILD_ID' ) ?: '0' branch = System.getenv( 'BRANCH' ) ?: 'development' } +if ( branch == 'development' ) { + // If the branch is 'development', ensure the version ends with '-snapshot' + // This replaces any existing prerelease identifier with '-snapshot' + version = version.contains('-') ? version.replaceAll(/-.*/, '-snapshot') : "${version}-snapshot" + boxlangVersion = boxlangVersion.contains('-') ? boxlangVersion.replaceAll(/-.*/, '-snapshot') : "${boxlangVersion}-snapshot" +} repositories { mavenLocal() @@ -32,10 +38,12 @@ dependencies { // Until BoxLang is published to Maven Central // Look for it in the local build directory // You must run `./gradle build -x test` in the BoxLang project + compileOnly files( '../../boxlang/build/distributions/boxlang-' + boxlangVersion + '-all.jar' ) compileOnly files( 'src/test/resources/libs/boxlang-' + boxlangVersion + '-all.jar' ) implementation 'org.python:jython-slim:2.7.4' // Testing Dependencies + testImplementation files( '../../boxlang/build/distributions/boxlang-' + boxlangVersion + '-all.jar' ) testImplementation files( 'src/test/resources/libs/boxlang-' + boxlangVersion + '-all.jar' ) testImplementation "org.junit.jupiter:junit-jupiter:5.+" testImplementation "org.mockito:mockito-core:5.+" diff --git a/changelog.md b/changelog.md index 735c7e0..5c8d0b2 100644 --- a/changelog.md +++ b/changelog.md @@ -9,6 +9,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +- Updated build libraries +- Upgraded internal libraries for build +- Upgraded Jython to 2.7.4 + ## [1.0.0] - 2024-06-17 - Support eval and bindings diff --git a/gradle.properties b/gradle.properties index 2433874..9b6de35 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,5 +1,5 @@ #Mon Jun 17 21:47:29 UTC 2024 -boxlangVersion=1.0.0-beta2 +boxlangVersion=1.0.0-snapshot jdkVersion=21 version=1.1.0 group=com.ortussolutions diff --git a/grapher/data/lastAST.json b/grapher/data/lastAST.json deleted file mode 100644 index 3b17701..0000000 --- a/grapher/data/lastAST.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "ASTType" : "BoxScript", - "ASTPackage" : "ortus.boxlang.compiler.ast", - "sourceText" : "", - "position" : { - "start" : { - "line" : 1, - "column" : 0 - }, - "end" : { - "line" : 2, - "column" : 5 - } - }, - "comments" : [ { - "ASTType" : "BoxSingleLineComment", - "ASTPackage" : "ortus.boxlang.compiler.ast.comment", - "sourceText" : "// Testing code here", - "position" : { - "start" : { - "line" : 1, - "column" : 0 - }, - "end" : { - "line" : 1, - "column" : 20 - } - }, - "comments" : [ ], - "commentText" : "Testing code here" - } ], - "statements" : [ ] -} \ No newline at end of file