File tree 2 files changed +9
-2
lines changed
danger-kotlin/src/runnerMain/kotlin/systems.danger/cmd/dangerjs
2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change 15
15
- Migrate from moshi to kotlinx serialization [ @gianluz ] - [ #141 ] ( https://github.com/danger/kotlin/pull/141 )
16
16
- Fix incorrect url in install.sh script and in Dockerfile [ @davidbilik ] - [ #144 ] ( https://github.com/danger/kotlin/pull/144 )
17
17
- Road to 1.0 - Refactor project structure [ @gianluz ] - [ #142 ] ( https://github.com/danger/kotlin/pull/142 )
18
+ - Handle danger-js custom paths with parameter ` --danger-js-path ` [ @f-meloni ] - [ #153 ] ( https://github.com/danger/kotlin/pull/153 )
18
19
- Update Kotlin to 1.4.20 [ @gianluz ] - [ #148 ] ( https://github.com/danger/kotlin/pull/148 )
19
20
- Fix gitlab defaults following kotlinx serialisation [ @gianluz ] - [ #146 ] ( https://github.com/danger/kotlin/pull/146 )
20
21
- Road to 1.0 - Migrate from java.util.Date to kotlinx.datetime [ @gianluz ] - [ #147 ] ( https://github.com/danger/kotlin/pull/147 )
Original file line number Diff line number Diff line change @@ -4,11 +4,17 @@ import systems.danger.Log
4
4
import systems.danger.cmd.Cmd
5
5
6
6
object DangerJS: DangerJSBridge {
7
-
8
7
override fun process (command : String , processName : String , args : List <String >) {
9
8
Log .info(" Launching Danger-JS" , verbose = true )
10
9
with (Cmd ()) {
11
- name(" $(which danger) $command --process $processName --passURLForDSL" )
10
+ val dangerJSArgumentIndex = args.indexOf(" --danger-js-path" )
11
+ val dangerJSPath: String
12
+ if (dangerJSArgumentIndex != - 1 && args.count() > dangerJSArgumentIndex + 1 ) {
13
+ dangerJSPath = args[dangerJSArgumentIndex + 1 ]
14
+ } else {
15
+ dangerJSPath = " $(which danger)"
16
+ }
17
+ name(" $dangerJSPath $command --process $processName --passURLForDSL" )
12
18
args(args.joinToString(" " ))
13
19
exec()
14
20
}
You can’t perform that action at this time.
0 commit comments