gradle-josm-plugin / org.openstreetmap.josm.gradle.plugin.config / I18nConfig / getPathTransformer

getPathTransformer

fun getPathTransformer(repoUrl: String): (String) -> String

Creates a path transformer that replaces an absolute file path of the *.pot file with a URL to a hosted instance of the project. Supply a base URL to a source code browser on the web, it will be transformed to the full URL as follows:

$repoUrl/$gitCommitHash/$filePathRelativeToProjectRoot#L$lineNumber

Good values would be e.g. gitlab.com/myself/MyAwesomeProject/blob or github.com/myself/MyAwesomeProject/blob

Parameters

repoUrl - the supplied base URL

Since
0.4.7