jmfayard
07/11/2022, 8:54 AMFleshgrinder
07/11/2022, 10:39 AMjmfayard
07/11/2022, 11:40 AM./gradlew suggestVersions
GitHub Action gives us
1. a VM to run it (Azure, UbuntuLatest, Java 11) - but it could be multiple OS / java versions / ⌠if for example you have a multiplatform library
2. a way to store environment variables and secrets
3. an event on when we want it to run. It could be a pull request or in this case a Crontab that runs once a week.
4. a way to create an issue like this one automatically depending on what the Gradle task foundFleshgrinder
07/11/2022, 1:37 PMPiotr KrzemiĹski
07/11/2022, 2:30 PMPiotr KrzemiĹski
07/11/2022, 2:32 PMjmfayard
07/11/2022, 2:40 PMFleshgrinder
07/11/2022, 5:02 PMCtrl
+ Space
in IntelliJ does it for me based on the backing JSON schemas directly from GitHub. Combining that with Workflow Starters there is not often the need for anyone to actually write these YAML files. Sure, in special cases, but considering that special cases are not the norm anyone would need to make themselves familiar with whatever abstraction is in place to get where they want to get. I fail to see how additional libraries (that require additional maintenance) help here.
The examples given in your blog post quickly fall apart. The auto-completion for an action like CheckoutV3
are only available because somebody actually wrote it. But, what about all the other actions out there where nobody ever wrote a Kotlin class for? What's really needed here is IDE support to automatically fetch the action schema so that the parameters can be auto-completed properly. Same goes for the version, again something the IDE can do much more reliably for any kind of action out there.
Hence, what would be truly worthwhile would be an IDE plugin that understands GitHub actions and can provide inline help for them. Just like the JSON schema can provide it for the GitHub workflow YAML files.Vampire
07/11/2022, 5:15 PMFleshgrinder
07/11/2022, 5:32 PMVampire
07/11/2022, 6:51 PMFleshgrinder
07/11/2022, 7:06 PMVampire
07/11/2022, 7:16 PMVampire
07/11/2022, 7:23 PMFleshgrinder
07/11/2022, 7:32 PMVampire
07/11/2022, 7:45 PMFleshgrinder
07/11/2022, 7:49 PMjmfayard
07/12/2022, 3:59 AMThe examples given in your blog post quickly fall apart. The auto-completion for an action likeThe thing is that pretty much everything is automated. We add the coordinates of the action in our wrapper generator and Kotlinpoet generates it all. And later GitHub Actions runs regularly to check if there are new parameters or newer versions. So itâs pretty much what you hope for (the IDE fetching the action to see whatâs available). The difference is that instead of GitHub inventing a new subpar programming language and expecting JetBrains and the others IDE to build decent tooling for it, we leverage the excellent tooling that already exists for Kotlinare only available because somebody actually wrote it. But, what about all the other actions out there where nobody ever wrote a Kotlin class for?CheckoutV3
jmfayard
07/12/2022, 4:01 AM{{some.horrible.type.unsafe.magic}}
We just released type-safe expressions and I think they are pretty cool:
https://krzema12.github.io/github-actions-kotlin-dsl/user-guide/type-safe-expressions/jmfayard
07/12/2022, 5:25 AM