mirror of https://github.com/sbt/sbt.git
@olegych reported that sbt would silently swallow the 'compile' command in the multi-command, 'run;compile;reload'. I tracked this down to the build source check. When the build has Global / onChangedBuildSource := ReloadOnSourceChanges, the check build sources command return a new state with "reload" prefixed. To actually perform the reload, I returned this modified state with the prefixed reload command. There were two problems with this: 1) In the auto-reload case, the current command was not run after the reload 2) If the multi-command contained reload, the auto-reload check would have a false positive which triggered the bug in (1) To fix this, I clear out the remaining commands before I run the check command. That way, we know that if the remaining commands has a reload, then it is an auto-reload. We then prefix the state with both the reload and the current command. I updated the scripted test for auto-reload to handle multi commands containing reload. |
||
|---|---|---|
| .. | ||
| src | ||
| NOTICE | ||