-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DEV2-2461: Create a thin plugin for IJ for publishing (#512)
- Loading branch information
Assaf Sapir
authored
Apr 24, 2023
1 parent
f208eda
commit 9c6a00a
Showing
26 changed files
with
657 additions
and
209 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,6 @@ | |
<vendor email="[email protected]" url="https://tabnine.com">Tabnine</vendor> | ||
|
||
<extensions defaultExtensionNs="com.intellij"> | ||
<preloadingActivity implementation="com.tabnineSelfHosted.Initializer"/> | ||
<postStartupActivity implementation="com.tabnineSelfHosted.Initializer"/> | ||
</extensions> | ||
<description><![CDATA[ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile | ||
import java.util.stream.Collectors | ||
|
||
plugins { | ||
id 'java' | ||
id "org.jetbrains.kotlin.jvm" version "1.4.32" | ||
id 'org.jetbrains.intellij' version '1.13.3' | ||
id 'org.jlleitschuh.gradle.ktlint' version "10.0.0" | ||
id 'org.jlleitschuh.gradle.ktlint-idea' version "10.0.0" | ||
id "com.github.sherter.google-java-format" version "0.9" | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
group 'com.tabnineSelfHosted' | ||
version '0.0.1' | ||
|
||
sourceCompatibility = 9 | ||
targetCompatibility = 9 | ||
|
||
tasks.withType(KotlinCompile).configureEach { | ||
kotlinOptions { | ||
jvmTarget = "9" | ||
} | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
apply plugin: "org.jlleitschuh.gradle.ktlint-idea" | ||
|
||
dependencies { | ||
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.4.32") | ||
} | ||
|
||
intellij { | ||
version = '2019.3' | ||
type = 'IC' | ||
updateSinceUntilBuild = false | ||
} | ||
|
||
tasks.create("currentVersion") { | ||
doLast { | ||
println version | ||
} | ||
} | ||
|
||
tasks.getByName("runIde").configure { | ||
if (project.hasProperty('logFilePath')) { | ||
systemProperty("TABNINE_LOG_FILE_PATH", logFilePath) | ||
} | ||
} | ||
|
||
tasks { | ||
compileKotlin { | ||
dependsOn(ktlintFormat) | ||
} | ||
} | ||
|
||
static def getIdeVersions(Project project) { | ||
def ideVersions = project.hasProperty('ideVersions') ? | ||
Arrays.asList(project.ideVersions.split(',')) : | ||
['IC-2019.3.5'] | ||
return ideVersions | ||
} | ||
|
||
runPluginVerifier { | ||
ideVersions = getIdeVersions(project) | ||
if (project.hasProperty("localPaths")) { | ||
localPaths = Arrays.stream(project.localPaths.split(',')).map(File::new).collect(Collectors.toList()) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.