I created the TDD Gilded Rose codebase in 2021, when the default for Gradle build scripts was the Groovy language. Since then I’ve tried to convert to the Kotlin DSL at least 3 times, and every time I’ve been beaten by some difficulty that just made the conversion uneconomic.
Whatever you think about them, LLMs are certainly changing software economics at a rapid pace, so let’s have another go, this time with AI Assistance.
In this episode
00:00:32 Gradle's guide to migration
00:01:42 Enter AI Assistant
00:02:52 The result doesn't compile, so let's go and fix things
00:05:32 Are vals and ext equivalent?
00:05:55 Now we just have issues with the jOOQ plugin
00:07:01 Pull syntax over from the plugin documentation
00:09:38 Syntax highlighting works, when there are no syntax errors
00:09:53 Now it compiles we can check it works
00:10:41 Can we remove some of the syntax that we have added?
00:11:11 Import quick fix fails and then crashes
00:12:12 Operator fun invoke allows us to prepend a block to an expression
00:13:06 Invoke quick fix not working in the script
00:13:48 Gah another crash
00:14:35 AI Assistant for migrating compiler options
00:15:17 Before vs After
00:16:03 Future Duncan prefers Claud
00:17:29 Wrap up
There is a playlist of TDD Gilded Rose episodes - • Test Driven Gilded Rose in Kotlin
The codebase is available on GitHub https://github.com/dmcg/gilded-rose-tdd
I get lots of questions about the test progress bar. It was written by the inimitable @dmitrykandalov. To use it install his Liveplugin (https://plugins.jetbrains.com/plugin/...) and then this gist https://gist.github.com/dmcg/1f56ac39...
If you like this video, you’ll probably like my book Java to Kotlin, A Refactoring Guidebook (http://java-to-kotlin.dev). It's about far more than just the syntax differences between the languages - it shows how to upgrade your thinking to a more functional style.
Смотрите видео Groovy to Kotlin - Migrating a Gradle Build онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Pairing with Duncan 01 Ноябрь 2024, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 787 раз и оно понравилось 62 людям.