I've tested your script in Chrome (with the Tampermonkey
extension) and it seems to work correctly for me without
modification (I did see that there was a missing ; on
line 26 but it worked without it anyway), when I click the
Last header it selects all the packages in the
Last column and if I click the Latest
header it selects all the packages in the Latest
Yeah the radio buttons do get selected - but the changes are not propagated to the release.
Ie, by default "Latest" items are selected. Then I click on the "Last" column header and Greasemonkey selects "Last" items for all packages. But when I click "Create Release" I see that Octopus picked up "latest" packages to deploy, not the "last" ones.
I think it's not enough to select radio buttons on the UI, the script needs to update Angular models - which is why I added "//update ng model" code. But looks like it's not enough.
If some UI developer from Octopus team could advise that would be great!
If you update the @include URL to have
/*/projects/*/releases/create instead of just
*, the script will only run on the release creation
I've created this
UserVoice ticket to provide first class support for your
scenario and see what the community thinks about it, as we don't
generally recommend writing these types of scripts as it may (as
you've seen) interfere with other parts of the app.