Mathias Quintero
83087291df
Add API to get locations of collected script annotations
...
#KT-38404 fixed
also:
- Add wrapper class for the location combined with the location id
- Add source code location parameters to external dependency resolvers
- Add tests for locations in annotations
- Add tests for order of annotation resolution for dependencies resolvers
2020-06-10 16:28:41 +02:00
Ilya Chernikov
c112d37ac1
Consolidate resolving in the new lib, deprecate it in script-util
...
also deprecate Import and CompileOptions annotations, because they
do not seem generic enough. Create specific copie in the main-kts
instead.
2020-05-21 16:49:57 +02:00
Ilya Chernikov
7d426226f9
Switch example to the new maven resolving API
2020-05-21 16:49:56 +02:00
Ilya Chernikov
b96109f23f
Add diagnostic code to the ScriptDiagnostic
...
to allow checking for specific errors, e.g. incomplete statements in
the REPL
2020-02-13 11:33:40 +01:00
nikita.movshin
65244b4bea
Update copyright.
...
Change the copyright from "JetBrains s.r.o." to
"JetBrains s.r.o. and Kotlin Project contributors"
Update only 2 lines copyright.
2019-04-23 20:09:22 +03:00
Ilya Chernikov
2bb5e8f51f
Implement and use helpers for economical classpath update in script configs
2019-01-18 18:17:45 +01:00
Ilya Chernikov
44ea2bf1d4
Introduce script names and location ids, use them in diagnostics and...
...
for virtual file names. Also fix compiled script serialization.
2018-12-20 17:09:23 +01:00
Ilya Chernikov
a02d5b4b21
Rename script annotation params according to configuration keys...
...
rename evaluation params consistently too
2018-09-11 14:56:51 +02:00
Ilya Chernikov
d6590d4fa3
Scripting examples refactoring
2018-09-06 19:17:43 +02:00
Ilya Chernikov
01eca8bac8
Clean up properties collection
2018-08-23 09:51:53 +03:00
Ilya Chernikov
bb22dadc1e
Rearrange compilation related API
2018-08-23 09:51:53 +03:00
Ilya Chernikov
bd8f2a81e9
Rename ScriptDefinition to ScriptCompileConfiguration
2018-08-23 09:51:53 +03:00
Ilya Chernikov
acb0f6c6a9
Remove ScriptCompileConfiguration as separate entity, refactor pieces accordingly
2018-08-23 09:51:53 +03:00
Ilya Chernikov
ab63d59a56
Refactor definition keys
2018-08-23 09:51:53 +03:00
Ilya Chernikov
04ffe7754e
Refactoring properties collection after review
2018-08-23 09:51:53 +03:00
Ilya Chernikov
74f8a541c0
Grand refactoring of the scripting DSL + many minor usability refactorings around it
2018-08-23 09:51:53 +03:00
Ilya Chernikov
3fb3aa5ad1
Setup props once, fix initialization problem
2018-08-23 09:51:53 +03:00
Ilya Chernikov
70ec004aaa
Sorting default jvm props and basic implementations
2018-08-23 09:51:53 +03:00
Ilya Chernikov
fe2a11142e
Renaming, commenting sample
2018-08-23 09:51:53 +03:00
Ilya Chernikov
3629583942
Add overridable method "setup" for defining properties
2018-08-23 09:51:53 +03:00
Ilya Chernikov
1de37ca765
Make KotlinScript annotation accepting all params needed to define a script
2018-08-23 09:51:53 +03:00
Ilya Chernikov
dafbd59707
Add shorter aliases for properties
2018-08-23 09:51:53 +03:00
Ilya Chernikov
df870b47b8
Add helpers for jvm dependencies from context
2018-08-23 09:51:53 +03:00
Ilya Chernikov
100b908a94
Add properties builders to the dsl, implement a builder for refineConfiguration
2018-08-23 09:51:53 +03:00
Ilya Chernikov
e5e1b8d100
Improve generic DSL
2018-08-23 09:51:53 +03:00
Ilya Chernikov
7a621405ae
Add generic properties builder dsl, convert maven example to it
2018-08-23 09:51:53 +03:00
Ilya Chernikov
cf2162c445
Refactor properties
2018-08-23 09:51:53 +03:00
Ilya Chernikov
8953bba47c
Pass scripting (host) environment independently from properties/configuration
2018-08-23 09:51:53 +03:00
Ilya Chernikov
91e6c0b77c
Remove evaluator from script definition, simplify interface
2018-08-23 09:51:53 +03:00
Ilya Chernikov
e61ba1fd70
Replace dedicated configurator with definition properties + refine fun
2018-08-23 09:51:53 +03:00
Ilya Chernikov
5af490f5e5
Remove script discovery files from example projects to avoid discovery problems:
...
- exception during loading of the definition with maven dependencies
- shading of the gradle script definition (if not fixed by the previous commit)
The discovery files should be restored after fixing/rewriting the discovery
and implementing definition prioritization in IDEA plugin
2018-04-27 09:03:15 +02:00
Ilya Chernikov
51888154e1
Change custom script examples file extensions:
...
fixes shadowing of the gradle script definitions after these example
script defs are loaded via discovery mechanisms
2018-04-27 09:03:15 +02:00
Alexander Udalov
914cf18051
Fix line separators in scripting-related build.gradle.kts files
2018-04-04 22:26:17 +02:00
Ilya Chernikov
599a9acce8
Rearrange scripting examples to conform the build system requirements
2018-04-04 16:23:58 +02:00
Ilya Chernikov
7fbcfdf09e
Add config params for specifying target annotations, import param renaming
2018-04-04 16:23:58 +02:00
Ilya Chernikov
191b1cfefa
Refactor configurations handling:
...
- rearrange compile call parameters for clarity, more defaults
- remove baseConfiguration method - it is now covered by defaultConfiguration
for static part, and refineConfiguration call if a config parameter is
specified
- implement proper configurations chaining, documented in comment to compile function
- minor renamings and refactorings
2018-04-04 16:23:58 +02:00
Ilya Chernikov
4a4edf3458
[minor] Renames and rearrangements for clarity
2018-04-04 16:23:58 +02:00
Ilya Chernikov
5058c66e8c
Refactor scripting properties:
...
- flatten the structure
- add some parameters
- replace iterables with lists
- renaming all scope objects uniformily
also:
- fix passing and usage of script sources
- renamings and other minor improvements
2018-04-04 16:23:58 +02:00
Ilya Chernikov
2ddcc280a9
Implement simplified property bag dsl:
...
move it to the separate jar,
use property bag chaining
2018-04-04 16:23:57 +02:00
Ilya Chernikov
495c75c48e
Rename heterogeneous map to PropertyBag, make it chainable
...
the commit is needed to implement single chained script configuration bags
2018-04-04 16:23:57 +02:00
Ilya Chernikov
29797ec264
Switch to plugins section in scripting build files after rebasing
2018-04-04 16:23:57 +02:00
Ilya Chernikov
ae2af238fa
Fixes after refactoring the API
2018-04-04 16:23:57 +02:00
Ilya Chernikov
2c3a50e4b3
Refactor scripting examples:
...
- split into script def and host part
- remove bad dependencies
- organize it in a way that should be typical for user scenarios
2018-04-04 16:23:56 +02:00