Kotlin Rules 1.5.0 (Beta 4)
Pre-releaseNote: These rules are maintained externally by volunteers (with Google's approval)
Note: The "legacy" prefix will be dropped as of this release. These are the rules, from this point on, until and unless Google chooses to externalize internal rules, at which point we can differentiate.
Note: legacy-1.4.0 isn't released, and this release includes all features in that line of development. Many of those changes are included in this list.
Beta 4 Revisions
- Add --exclude_build_data arguemtn to singlejar invocation (#566)
- Version the kt_kotlinc_options and kt_javac_options. (#564)
- Bump Android build-tools to 30.0.3 (#568)
- Fix using rules_kotlin from head (#571)
- Support explicit API mode (#576)
- Kotlin 1.5 support (#577)
- Fix missing dependency on jvm-abi-gen.jar in release artifacts (#569)
- Trim worker output before emitting it (#586)
- Other fixes, typos, and erratta.
Beta 3 Revisions
- Fix duplicate testonly attributes being passed to kt_android_local_test (2e7d520)
- Call System.gc between work requests (#558)
- Revert "Isolate Kotlin compiler instances for Multiplex workers. (#515)
- Fix duplicate worker output (#561) …
- Add forwarding references for js, jvm, ktlint. (#557)
- Should fix the need to import rules_android if you don't use them
- May require changing load() statements to point at different .bzl
e.g.kt_jvm_library
would be loaded fromjvm.bzl
instead ofkotlin.bzl
Beta 2 Revisions
- Handle properties from companion objects (#470)
- Persistent workers: exit if stdin is closed (#472)
- Fix build failure when using Java only modules with annotation processor (0ebede9)
- Collect references for type declarations. (#475)
- Add java_parameters kt_kotlinc_option (#477)
- Additional jdeps cases in Kotlin (8a8e884)
- Support optional source_jar (#482)
- Pass a few more args to android_local_test (38548a6)
- Add multiplex worker support (#481)
- More jdeps fixes (#484)
- pass the multiple platform flag to kotlinc (#487)
- Fix jdeps collectTypeArguments stackoverflow error (51fe508)
- make multiplxing parallel. (#496)
- Fix concurrency for multiplex (#498)
- Parallelize stdout and clean up PersistentWorker (#501)
- Introduce ktlint_test and ktlint_fix (#502)
- Support manifest_values in android_local_test
- Add missing variables for java stub template. (#504)
- Disable spammy output for jar creation. (#503)
- Initial (experimental) support for code coverage. (#505)
- source jars passed as rule srcs attributes were being included as nested (80e545c)
- Add support for Kotlin coverage (#508)
- Fix java.version parsing (#510) (#511)
- Implement better test class inference. (#516)
- Isolate Kotlin compiler instances for Multiplex workers. (#515)
- Fix kt_jvm_test to support mixed java/kt srcs (#513)
- Enable worker-key-mnemonic for KotlinCompile + KotlinKapt. (#518)
- Pass strict_deps flag to java compiler in JavaBuilder flow (#524)
- Fix formatting in JavaCompiler class (#490)
- Add jdeps recursion tests (#488)
- Fix kotlin compiler_release not being set (#530)
- Remove jcenter references (#526)
- Pass tags to android sandwich (#525)
- Expose parcelize plugin and add an example for using it (#522)
- Remove deprecated java_common fields (#519)
- Fix missing dependency on @com_github_jetbrains_kotlin//:lib/jvm-abi... (6dfa4bb)
- fix(docs): correct markdown syntax (#533)
- Update Dagger from 2.28 -> 2.35.1 (#543)
- Update to Bazel 4.1.0 (#542)
- Use current java_stub_template (#545)
- Fix generated resources (#538)
- Fix kt_android_local_test can't depend on testonly libraries (#537) …
- Support srcjars in mixed Java/Kotlin sources when ABI jars are enabled ( …
- various housekeeping PRs.
Beta 1 Revisions
- Strict dependency checking and enforcement. (#438)
- Add a tristate (off/warn/error) experimental_report_unused_deps (#437)
- Add docs for experimental_use_abi_jars (#446)
- Kotlin Builder reduced classpath - experimental feature (#439)
- Improve Jdeps to handle:- (#449)
- Add Jetpack Compose example (#450)
- Add support for kt_android_local_test (#451)
- [Jdeps] Fixes for more missing cases discovered during testing (#452)
- Ignore the jetpack compose example project from the main (avoids //..… (f7ea228)
- Make the release script a wee bit clearer, and add generate a sha256
- Fix breakage due to no jdeps produced when no KT source. (#457)
- Fix test class checking to break when it finds a match. (#464)
- Add missing AP files to fix references in Android Studio IDE (#459)
- Fix examples/android code to actually run successfully (#443)
- Support tracking super types that are not explicitly referenced as (#468)
- Expose kotlinc's -Xfriend-paths to all jvm/android kt rules under the… (15dd1de)
- Make all the child workspaces share the same .bazelversion. (#466)
- Delete orphan code not used anywhere. (#467)
Alpha 3 Revisions
- Fixed default option visibility
- Bump to project Kotlin 1.4.20
Alpha 2 Revisions
- JavaBuilder compilation prerelease available for testing using:
--define=experimental_use_abi_jars=1
- jdeps automatically generated from
kt_jvm_library
rules. - Support for
kt_kotlinc_options
tokt_jvm_library
. Library options supersede toolchain options. - Added
kt_kotlinc_options
:
Notable changes:
- Releases are now precompiled, suggested production installation is via a release archive. Please see the Development Guide
- when running from a non-archive repository. (#271)
- Support for Kotlin compiler plugins via the kt_compiler_plugin (#308)
- Improved determinism for remote builds (#304)
- No longer packages non-kotlin generated sources (#263)
- Proper classpath handling for java plugins (#318)
- Support for propagating Kotlin version to Intellij (#242 )
- Fixes to release artifact production (#326, #327)
- Restructure the worker to be deterministic (cc039db, 3f4698a)
- Support to compilation using kotlin abi and java ijars. (#294, #347)
- Add support for Android data-binding when building with Kotlin (#346)
- Add 0 to allowed package name characters (#364)
- Specify what the compile_jar value should be when building the library (#341)
- Separate
--Xplugin
options to support multiple compiler plugins at a time (#366) - Fix setting tags = ["trace", "timings"] on a rule. (#378)
- Kotlin 1.4 (#363)
- Support multiple source jars (#377)
- Bump serialization runtime to compatible version (#382)
- Add option rules for kotlinc and javac. (#383, #385)
- Expose kt_kotlinc_options and kt_javac_options (#386)
- Make kt_compiler_plugin work with android_binary (#388)
- Support the new Kotlin IR backend (#384)
- Add warning as error to the warn option. (b7f5832)
- Major rework of the compiler plugin infrastructure (#393)
- plugins now require an ID (formerly optional)
- plugins run in specific phases (kapt stubs, compile)
- compiler plugins may be exported via
exported_compiler_plugins
(similar toexported_plugins
on java_library) - some bash substitutions in working directory arguments in plugins (anvil example demonstrates)
- Option to tag a rule as kt_abi_plugin_incompatible (#362) …
- Fix java_plugins to work with Android rules (#407)
- Include KAPT generated source jars as Kotlin builder inputs (#410)
- Unify experimental java builder + abi jar flags (#411)
- Many more minor fixes.
More detail can be found in the Changelog
Usage instructions can be found in the readme README
This release includes the contributions of various Googlers as well as @cgruber, @justhecuke, @szinn, @rockwotj, @IljaKroonen, @benjaminRomano, @factuno-db, @arturdryomov, @restingbull, @jongerrish, @BenHenning, @gertvdijk, @dotdat, @fkorotkov, @Wyverald, @Bencodes, @Kernald, @meteorcloudy, @comius.
SHA-256 for rules_kotlin_release.tgz
: e4185409c787c18f332ae83a73827aab6e77058a48ffee0cac01123408cbc89a