Skip to content

Latest commit

 

History

History
415 lines (295 loc) · 16.9 KB

NEWS.adoc

File metadata and controls

415 lines (295 loc) · 16.9 KB

Changes

[4.2.3] - 2023-07-22

Fixed

  • Compatibility with Kotlin 1.9.0

[4.2.2] - 2023-04-29

Added

  • Updated Gradle to version 8.0.2

Fixed

  • Fixed handling path with spaces on Windows #397 (thanks to ckaag)

  • Fixed build script (dependencies between tasks)

  • Fixed reading Unicode characters from executed scriptlets

  • Fixed Windows integration tests

[4.2.1] - 2023-01-26

Added

Fixed

  • The correct way of resolving kscript binary on Windows (thanks to goto1134)

[4.2.0] - 2023-01-14

Breaking changes

  • Renamed environment variable from 'KSCRIPT_DIR' to 'KSCRIPT_DIRECTORY'

Added

  • New GitHub organization: kscripting

  • More work on Windows shell compatibility; most functionality works on Windows as on systems with bash

  • Change the name of kscript package to io.github.kscripting:kscript

  • Final execution of script is handled by kscript, not by bash (reduces dependency on bash)

  • Separate library for shell execution kscripting/shell

  • Ability to provide local artifacts path through KSCRIPT_DIRECTORY_ARTIFACTS or configuration file property: scripting.directory.artifacts (thanks to Vsajip for initial implementation)

  • kscript jar is released to Maven Central: io.github.kscripting:kscript:4.2.0

  • Change the way of checking latest kscript version (simplifies releases)

  • Deprecate old annotations in kscript-annotations library

  • Improved implementation: VersionChecker, ConfigBuilder etc.

  • Updated Gradle and dependencies

  • Deprecated @file:Include in favour of @file:Import as a preparation of switch to Kotlin Scripting

  • Replaced DocOpt with Apache CLI

  • Changed the way of creating distribution package - now it is handled by Gradle

  • Version of kscript is set by Gradle (generated BuildConfig class)

  • Improved DependencyResolver: aar archives are also included in classpath

  • When creating IntelliJ project Gradle and Idea are no more required

Fixed

  • Fixed exit code on Windows

[4.1.1] - 2022-08-27

Breaking changes

  • Renamed env variables (cleanup): CUSTOM_KSCRIPT_PREAMBLE -> KSCRIPT_PREAMBLE KSCRIPT_IDEA_COMMAND -> KSCRIPT_COMMAND_IDEA KSCRIPT_GRADLE_COMMAND -> KSCRIPT_COMMAND_GRADLE

Added

  • Windows support and proper Cygwin and MSys support

  • File argument for specific OS should be in format of that OS (eg. Cygwin: kscript /cygdrive/c/file.kts)

  • Multiplatform tests for different OS-es using Github actions

  • Ability to use configuration file for kscript (thanks to meztihn)

  • kscript follows XDG Spec (Issue #323) (thanks to meztihn)

  • Packaging scripts works again (thanks to Vsajip)

  • When creating IntelliJ project 'gradle' and 'idea' do not have to be in path

  • Integration tests rewritten from bash to JUnit

  • Replacements for (current annotations are deprecated):

    • @MavenRepository -> @Repository

    • @KotlinOpts -> @KotlinOptions

    • @CompilerOpts -> @CompilerOptions

  • Deprecation of comment based annotations

  • Report for deprecated features (–report option)

Fixed

  • Fix for dependency resolution

  • Fix for creation of Gradle files and their indentation

  • Fix for handling potentially duplicated file names in Idea projects

  • Fix for Idea runtime configuration

[4.0.3] - 2022-05-28

Functionality:

  • Recursive inclusion of dependant scripts without hardcoded limits

Improved test_suite.sh

  • Automatic setting up of test environment (assert.sh, test directories)

  • Automatic compilation

  • idea - script to help to test idea use cases

  • Script setup_environment.sh can be used for local testing

  • Some script tests moved to Unit Tests

  • Ability to start test suites by name

Improved Unit Tests

  • Several new Unit tests

  • New Unit Tests can be created much easier (Major point why modularization makes sense)

Improved Logging

  • Silent mode / Development mode logging

Modularisation of source code

  • Removed duplication

  • Code divided in logical pieces and moved to packages

  • Script resolution creates immutable objects

Build script

  • Updated Gradle to version 7.4.3 and shadowJar to 7.1.2

  • Fixes in build file

Performance

  • Much less IO operations - that should contribute to better performance

Misc

  • Updated Kotlin to 1.5.31, but only for compiler, not kotlin-scripting. It’s far from optimal, but it is not possible to move fully to Kotlin 1.5 or even 1.6, because of the issues with resolution of artifacts in latest kotlin-scripting. I have put report here: https://youtrack.jetbrains.com/issue/KT-49511

  • Fixed a lot of IDE warnings in code

  • Packaging - gradle file converted to Kotlin; still does not work, but it was like that before anyway

  • Changes for kscript dir allow simple implementation of config file if needed. (.kscript/kscript.config); Not implemented by me, but might be useful e.g. for storing preambles

Breaking changes

  • In annotations the only allowed delimiter is coma "," (to allow options with arguments, separated by space)

  • Resolution of env variables is more restrictive - only vars expected by kscript can be resolved (for security - it’s not good to include arbitrary strings from user env into the script)

  • Reworked caching mechanism

[3.2.0]

Not released - incorporated in 4.0

Major changes & enhancements

  • Improved for relative script inclusions (Thanks to PR by aartiPI #330)

  • Fixed bootstrap header support (#324)

[3.1.0]

Major changes & enhancements

  • Removed jcenter as default dependency repository

  • Updated tests and build integration to function without jcenter

[3.0.0]

Major Enhancements

Minor improvements

  • Forward jvm target to –idea generated build.gradle.kts (#258)

  • Add maven repo credentials to build.gradle.kts generated by –idea (#262)

  • Add option to launch temp intellij as custom command through env property (#264). E.g on ubuntu we could use export KSCRIPT_IDEA_COMMAND=/snap/bin/intellij-idea-ultimate to enable kscript --idea <script.kts>

  • Fixed idea project symlinks for complex projects (#268)

  • Fixed bootstrap script env variable issue (#271)

  • Fixed parsing of named arguments in @MavenRepository (fixes #274)

  • Added executable docker container to release plan (fixes #224)

  • Updated Kotlin to 1.4.10 (#283)

  • Updated gradle in temporary projects to 6.7 (#282)

  • Add Kotlin run configuration for .kt based scripts. (#284)

  • Use absolute paths to avoid issues with relative paths and relativize (#285)

Incompatible API changes

  • Pom dependencies must be now declared as org.javamoney:moneta:pom:1.3 (and no longer as org.javamoney:moneta:1.3@pom)

  • Dynamic version dependencies must be now declared as log4j:log4j:[1.2,) (and no longer as log4j:log4j:1.2+)

[2.9.0]

Support environment variables in repository credentials (#248)

  • Make INCLUDE directive files relative to script dir

  • Create a default Run Configuration for Idea (#244)

Minor enhancements & fixes:

  • Support whitespace around maven repo credentials (fixes #228)

  • Make INCLUDE directive files relative to script dir

  • Fixed support for gitbash

  • Fixed bootstrap header (#234)

  • Improved and documented basic testing support (#247)

[2.8.0]

Improvements & Fixes

  • #214 Added credentials support for @file:MavenRepository annotation (thanks to @meonlol for providing the PR and his patience)

[2.7.0]

Improvements & Fixes

  • #159 Use aether instead of maven to pull dependencies

  • #210: Updated gradle capsule plugin

  • #102: Removed --self-update

  • Use resource from repo for resolve boostrap header

  • #203: Fix cache check bug on Windows

  • #199: Allow to bootstrap kscript installation with --add-bootstrap-header

  • #200: Expose script file name to script

[2.6.0]

Major Improvements

  • #166: Support dynamic versions ending with +

  • #185: Support "~" in INCLUDE ()

  • #187: Added support for shortened URLs

  • #146: Allow kscript cache directory to be configurable via KSCRIPT_CACHE_DIR environment variable

  • #175: cygwin support improvements

  • Improved kshell launcher to also launch scripts with invalid code

Notable Bug Fixes

  • Confusing error when filename starts with a number

  • Fixed usage @file:CompilerOpts in combination with @file:Include

  • Renamed kshell_from_kscript to kshell_kts

[2.5.0]

Major Improvements

  • Support dependencies with different types (pom instead of jar)

  • Use current kotlin for temporary project when using --idea

  • Started kshell launcher for kscriptlets

  • Support --idea with includes

Minor Enhancements

  • Avoid dependency duplications when using //INCLUDE recursively

  • Fixed: Unable to run script with plus character in filename

  • Allow to include same file from multiple files

  • Fixed: Space-containing argument propagation

[2.4.0]

Major Enhancements:

  • Allow to set kotlinc compiler flags with @file:CompilerOpts or //COMPILER_OPTS (#84). See here.

  • Provide a way to package kscripts (#63). See here.

Minor Enhancements:

  • Fixed #95: //INCLUDE requiring full path

  • Fixed #94: stdin does not allow further switches

  • Allow for round brackets in artifact ids (fixes #100).

  • Fixed #83: interactive fails unless your script contains dependencies

  • Fixed #82: Sym-linking does not work correctly with –idea and relative script paths

  • New: Implemented benchmarking suite to assess runtime impact of kscript

  • Fixed: Don’t use null in classpath arguments if classpath is empty

  • Fixed: Use exec for derived interpreter

  • Simplify Gradle config for script bootstrapping with IDEA (#86)

  • Added Gradle wrapper to the project (#87 and #88)

[2.3.0]

Major Enhancements:

  • Replaced javac with kotlinc for faster script compilation

  • Added symlink support

  • Allow to derive custom DSL interpreters from kscript (fixes #67)

  • Implemented @file:Include and @EntryPoint as documented in README ( fixes #73)

  • Added gitter channel

Minor Enhancements:

  • Consolidate imports and dependencies when //INCLUDE is used ( fixes #75) …

  • Support artifact should have better namespace (fixes #57)

  • Fixed #76: Unspecific error when dependency resolution fails

  • Fixed #66: It should die more gracefully if idea is not present

  • Fixed #81: Allow package declarations for scripts

  • Fixed #78: When using --idea the script argument should be symlinked

  • Fixed #79: Provide setup instructions if idea launcher is missing

  • Simplified build instructions (fixes #60)

  • Document dependencies of kscript (fixes #69)

[2.2.0]

  • Logging of maven artifact downloads to stderr (fixes #23)

  • Added -s / --silent to suppress all logging

  • Fixed #55: dependency resolution fails on travis ci and within docker containers

  • Added alternative @DependsOnMaven(val artifactId: String) annotaiton to declare dependencies. This has been implemented to make kscripts compatible with https://github.com/ligee/kotlin-jupyter

  • Added support for custom maven repositories (fixes #22)

See README for usage details.

[2.1.0]

  • support for annotation-driven script configuration

  • refactored support api mode into -t parameter

[2.0.0]

  • Reimplemented in kotlin (fixes #36)

  • Added cygwin support (fixes #39)

  • Added //INCLUDE directive (fixes #34

  • Fixed: interactive mode is not correctly started when using stdin as script argument (#40

  • Fixed compatibility with java9 (#41)

[1.5.1]

  • Fixed --self-update

  • More robust self-update on OSses with file-locking (e.g. windows)

[1.5.0]

  • removed curl dependency

  • more streamlined dependency lookup

[1.4.0]

Major new features

  • Redesigned support library for streamlined tabular data processing. See here for an overview.

[1.3.0]

Major new features

  • Dramatically reduced overhead by using dependency lookup cache more efficiently. After the initial scriptlet-jar-building, kscript runs with almost zero overhead now ( fixes #4)

  • Dependencies can now declared in multiple lines for better readability ( fixes #2)

  • Automatic inclusion of support library for one-liners (fixes #19)

  • Direct script arguments kscript 'println("hello kotlin")' ( fixes #18)

  • More robust dependency resolution with more informative error messages

Support API improvements

  • Kotlin DocOpt helpers to build CLIs (example)

  • New utilities to automatically resolve arguments files and stdin to Sequence<String for by-line processing

Other changes

  • Allow dependencies to be declared in multiple lines prefixed by //DEPS ( fixes #2)

  • To ensure long-term stability of kscript we’ve added a suite of unit tests. The repository tested continuously by Travis CI

  • Cache directory is now ~/.kscript

  • More heuristics to guess KOTLIN_HOME

  • Cache cleanup --clear-cache now applies to jars, scripts, urls, and cached dependency lookups

[1.2.0]

  • Fixed compatibility with Kotlin v1.1 (fixes #15)

  • Added -i to dump interactive console command incl deps ( fixes #10)

  • Compile jars should go to TEMP (fixes #13)

  • started test-suite

[1.1.0]

  • Support for stdin and process substitution as script source. See examples

  • versioning and auto-update

  • basic command-line help

  • Added support for KOTLIN_OPTS (see #8)

  • Added CLI help to resdeps.kts

  • Added option to clear dependency lookup cache: resdeps.kts --clear-cache

[1.0.0]

Initial Release