mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-15 02:59:33 +07:00
OPENIDE #81 Integration of Russian locale into OpenIDE
(cherry picked from commit a8dedc5a65ffb7d62567e2ca64f7657ab6852437)
This commit is contained in:
BIN
build/bundled-plugins/ru_pack/lib/intellij-ru-pack-0.0.1.jar
Normal file
BIN
build/bundled-plugins/ru_pack/lib/intellij-ru-pack-0.0.1.jar
Normal file
Binary file not shown.
@@ -14,20 +14,24 @@ import java.nio.file.Path
|
|||||||
|
|
||||||
object OpenIdePluginBundler {
|
object OpenIdePluginBundler {
|
||||||
|
|
||||||
private const val PLUGINS_DIR = "build/download/plugins"
|
private const val DOWNLOADABLE_PLUGINS_DIR = "build/download/plugins"
|
||||||
|
private const val PHYSICAL_PLUGINS_DIR = "build/bundled-plugins"
|
||||||
private const val AMPLICODE_URL = "https://amplicode.ru"
|
private const val AMPLICODE_URL = "https://amplicode.ru"
|
||||||
private const val AMPLICODE_MARKETPLACE_URL = "https://amplicode.ru/jetbrains-marketplace"
|
private const val AMPLICODE_MARKETPLACE_URL = "https://amplicode.ru/jetbrains-marketplace"
|
||||||
|
|
||||||
fun getBundlePluginPaths(context: BuildContext): List<Path> {
|
fun getBundlePluginPaths(context: BuildContext): List<Path> {
|
||||||
val communityHomeDir = context.paths.communityHomeDir
|
val communityHomeDir = context.paths.communityHomeDir
|
||||||
return listOf(Path.of("${communityHomeDir}/$PLUGINS_DIR/amplicode"))
|
return listOf(
|
||||||
|
Path.of("${communityHomeDir}/$DOWNLOADABLE_PLUGINS_DIR/amplicode"),
|
||||||
|
Path.of("${communityHomeDir}/$PHYSICAL_PLUGINS_DIR/ru_pack")
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bundleAmplicodePlugin(context: BuildContext) {
|
fun bundleAmplicodePlugin(context: BuildContext) {
|
||||||
val majorVersion = context.buildNumber.substringBefore('.')
|
val majorVersion = context.buildNumber.substringBefore('.')
|
||||||
val uri = resolveAmplicodeUri(majorVersion)
|
val uri = resolveAmplicodeUri(majorVersion)
|
||||||
val archivePath = BuildDependenciesDownloader.downloadFileToCacheLocation(COMMUNITY_ROOT, uri)
|
val archivePath = BuildDependenciesDownloader.downloadFileToCacheLocation(COMMUNITY_ROOT, uri)
|
||||||
val targetDir = context.paths.communityHomeDir.resolve("$PLUGINS_DIR/amplicode")
|
val targetDir = context.paths.communityHomeDir.resolve("$DOWNLOADABLE_PLUGINS_DIR/amplicode")
|
||||||
BuildDependenciesDownloader.extractFile(archivePath, targetDir, COMMUNITY_ROOT, BuildDependenciesExtractOptions.STRIP_ROOT)
|
BuildDependenciesDownloader.extractFile(archivePath, targetDir, COMMUNITY_ROOT, BuildDependenciesExtractOptions.STRIP_ROOT)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user