Right now we copy paste some code that extracts out the gradle or Maven version. This should be externalized. See https://github.com/spring-projects/spring-framework/blob/b656bb4855ba81cb775a47ce981bebb27a3e7218/.github/workflows/deploy-docs.yml#L28-L33