generated from JetBrains/intellij-platform-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial Implementation of BacktickFoldingBuilder and PrettyFoldingBui…
…lder
- Loading branch information
Showing
26 changed files
with
618 additions
and
179 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
.gradle | ||
build/ | ||
!gradle/wrapper/gradle-wrapper.jar | ||
!**/src/main/**/build/ | ||
!**/src/test/**/build/ | ||
|
||
### IntelliJ IDEA ### | ||
.idea/modules.xml | ||
.idea/jarRepositories.xml | ||
.idea/compiler.xml | ||
.idea/libraries/ | ||
*.iws | ||
*.iml | ||
*.ipr | ||
out/ | ||
!**/src/main/**/out/ | ||
!**/src/test/**/out/ | ||
|
||
### Eclipse ### | ||
.apt_generated | ||
.classpath | ||
.factorypath | ||
.project | ||
.settings | ||
.springBeans | ||
.sts4-cache | ||
bin/ | ||
!**/src/main/**/bin/ | ||
!**/src/test/**/bin/ | ||
|
||
### NetBeans ### | ||
/nbproject/private/ | ||
/nbbuild/ | ||
/dist/ | ||
/nbdist/ | ||
/.nb-gradle/ | ||
|
||
### VS Code ### | ||
.vscode/ | ||
|
||
### Mac OS ### | ||
.DS_Store | ||
/secret_key_ring_file.gpg | ||
/local.properties |
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,122 @@ | ||
import java.util.* | ||
plugins { | ||
kotlin("multiplatform") version "1.9.20" | ||
id("org.jetbrains.dokka") version "1.9.10" | ||
`maven-publish` | ||
signing | ||
} | ||
|
||
group = "io.github.kyay10" | ||
version = "1.0" | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
val dokkaHtml by tasks.getting(org.jetbrains.dokka.gradle.DokkaTask::class) | ||
|
||
val javadocJar: TaskProvider<Jar> by tasks.registering(Jar::class) { | ||
dependsOn(dokkaHtml) | ||
archiveClassifier.set("javadoc") | ||
from(dokkaHtml.outputDirectory) | ||
} | ||
|
||
kotlin { | ||
jvm() | ||
js(IR) | ||
val hostOs = System.getProperty("os.name") | ||
val isMingwX64 = hostOs.startsWith("Windows") | ||
when { | ||
hostOs == "Mac OS X" -> macosX64() | ||
hostOs == "Linux" -> linuxX64() | ||
isMingwX64 -> mingwX64() | ||
else -> throw GradleException("Host OS is not supported in Kotlin/Native.") | ||
} | ||
} | ||
|
||
publishing { | ||
publications { | ||
publications.withType<MavenPublication> { | ||
artifact(javadocJar) | ||
} | ||
} | ||
} | ||
|
||
// Stub secrets to let the project sync and build without the publication values set up | ||
ext["signing.keyId"] = null | ||
ext["signing.password"] = null | ||
ext["signing.secretKeyRingFile"] = null | ||
ext["ossrhUsername"] = null | ||
ext["ossrhPassword"] = null | ||
|
||
// Grabbing secrets from local.properties file or from environment variables, which could be used on CI | ||
val secretPropsFile = project.rootProject.file("local.properties") | ||
if (secretPropsFile.exists()) { | ||
secretPropsFile.reader().use { | ||
Properties().apply { | ||
load(it) | ||
} | ||
}.onEach { (name, value) -> | ||
ext[name.toString()] = value | ||
} | ||
} else { | ||
ext["signing.keyId"] = System.getenv("SIGNING_KEY_ID") | ||
ext["signing.password"] = System.getenv("SIGNING_PASSWORD") | ||
ext["signing.secretKeyRingFile"] = System.getenv("SIGNING_SECRET_KEY_RING_FILE") | ||
ext["ossrhUsername"] = System.getenv("OSSRH_USERNAME") | ||
ext["ossrhPassword"] = System.getenv("OSSRH_PASSWORD") | ||
} | ||
|
||
|
||
fun getExtraString(name: String) = ext[name]?.toString() | ||
|
||
publishing { | ||
// Configure maven central repository | ||
repositories { | ||
maven { | ||
name = "sonatype" | ||
setUrl("https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/") | ||
credentials { | ||
username = getExtraString("ossrhUsername") | ||
password = getExtraString("ossrhPassword") | ||
} | ||
} | ||
} | ||
|
||
// Configure all publications | ||
publications.withType<MavenPublication> { | ||
// Provide artifacts information requited by Maven Central | ||
pom { | ||
name.set("Prettify Kotlin Annotation") | ||
description.set("Provides a @Pretty annotation for Kotlin") | ||
url.set("https://github.com/kyay10/prettify-kotlin") | ||
|
||
licenses { | ||
license { | ||
name.set("Apache-2.0") | ||
url.set("http://www.apache.org/licenses/LICENSE-2.0") | ||
} | ||
} | ||
developers { | ||
developer { | ||
id.set("kyay10") | ||
name.set("Youssef Shoaib") | ||
email.set("[email protected]") | ||
} | ||
} | ||
scm { | ||
url.set("https://github.com/kyay10/prettify-kotlin.git") | ||
} | ||
} | ||
} | ||
} | ||
|
||
// Signing artifacts. Signing.* extra properties values will be used | ||
|
||
signing { | ||
sign(publishing.publications) | ||
} | ||
|
||
tasks.withType<AbstractPublishToMaven>().configureEach { | ||
val signingTasks = tasks.withType<Sign>() | ||
mustRunAfter(signingTasks) | ||
} |
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 @@ | ||
kotlin.code.style=official |
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
prettify-kotlin-annotation/gradle/wrapper/gradle-wrapper.properties
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,5 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.