|
| 1 | +plugins { |
| 2 | + id("java") |
| 3 | + id("org.jetbrains.kotlin.jvm") version "1.9.25" |
| 4 | + id("org.jetbrains.intellij.platform") version "2.2.1" |
| 5 | +} |
| 6 | + |
| 7 | +group = "io.truby" |
| 8 | +version = "0.1.5" |
| 9 | + |
| 10 | +repositories { |
| 11 | + mavenCentral() |
| 12 | + intellijPlatform { |
| 13 | + defaultRepositories() |
| 14 | + } |
| 15 | +} |
| 16 | + |
| 17 | +dependencies { |
| 18 | + intellijPlatform { |
| 19 | + intellijIdeaCommunity("2024.2") |
| 20 | + plugin("com.redhat.devtools.lsp4ij:0.19.0") |
| 21 | + bundledPlugin("org.jetbrains.plugins.textmate") |
| 22 | + pluginVerifier() |
| 23 | + zipSigner() |
| 24 | + testFramework(org.jetbrains.intellij.platform.gradle.TestFrameworkType.Platform) |
| 25 | + } |
| 26 | + |
| 27 | + testImplementation("org.junit.jupiter:junit-jupiter:5.10.2") |
| 28 | + testRuntimeOnly("org.junit.platform:junit-platform-launcher") |
| 29 | +} |
| 30 | + |
| 31 | +intellijPlatform { |
| 32 | + pluginConfiguration { |
| 33 | + id = "io.truby.t-ruby" |
| 34 | + name = "T-Ruby" |
| 35 | + version = project.version.toString() |
| 36 | + description = """ |
| 37 | + <p><b>T-Ruby</b> is a typed superset of Ruby, inspired by TypeScript. |
| 38 | + Add static type checking to your Ruby projects and catch errors before runtime.</p> |
| 39 | +
|
| 40 | + <h3>Features</h3> |
| 41 | + <ul> |
| 42 | + <li><b>Syntax Highlighting</b> - Full support for .trb and .d.trb files</li> |
| 43 | + <li><b>Code Completion</b> - Type-aware autocompletion</li> |
| 44 | + <li><b>Real-time Diagnostics</b> - See type errors as you type</li> |
| 45 | + <li><b>Go to Definition</b> - Navigate to symbols with Ctrl+Click</li> |
| 46 | + <li><b>Hover Information</b> - View type information on hover</li> |
| 47 | + <li><b>Compile Commands</b> - Compile .trb to .rb directly from IDE</li> |
| 48 | + </ul> |
| 49 | +
|
| 50 | + <h3>Requirements</h3> |
| 51 | + <ul> |
| 52 | + <li><a href="https://rubygems.org/gems/t-ruby">T-Ruby compiler</a> (gem install t-ruby)</li> |
| 53 | + <li><a href="https://plugins.jetbrains.com/plugin/23257-lsp4ij">LSP4IJ plugin</a></li> |
| 54 | + </ul> |
| 55 | +
|
| 56 | + <h3>Quick Start</h3> |
| 57 | + <ol> |
| 58 | + <li>Install T-Ruby: <code>gem install t-ruby</code></li> |
| 59 | + <li>Install LSP4IJ plugin</li> |
| 60 | + <li>Install this plugin</li> |
| 61 | + <li>Create a .trb file and start coding!</li> |
| 62 | + </ol> |
| 63 | +
|
| 64 | + <p>Learn more at <a href="https://type-ruby.github.io">type-ruby.github.io</a></p> |
| 65 | + """.trimIndent() |
| 66 | + changeNotes = """ |
| 67 | + <h3>0.1.2</h3> |
| 68 | + <ul> |
| 69 | + <li>Extended IDE compatibility (2024.2 - 2025.4)</li> |
| 70 | + <li>Improved plugin description and documentation</li> |
| 71 | + <li>Added plugin icon for JetBrains Marketplace</li> |
| 72 | + </ul> |
| 73 | +
|
| 74 | + <h3>0.1.1 - Initial Release</h3> |
| 75 | + <ul> |
| 76 | + <li>JetBrains Marketplace initial release</li> |
| 77 | + <li>LSP integration via LSP4IJ for language server support</li> |
| 78 | + <li>TextMate grammar for syntax highlighting</li> |
| 79 | + <li>File type support for .trb and .d.trb</li> |
| 80 | + <li>Compile T-Ruby file action (Ctrl+Shift+T / Cmd+Shift+T)</li> |
| 81 | + <li>Generate declaration file action (Ctrl+Shift+D / Cmd+Shift+D)</li> |
| 82 | + </ul> |
| 83 | + """.trimIndent() |
| 84 | + vendor { |
| 85 | + name = "T-Ruby" |
| 86 | + email = "support@type-ruby.io" |
| 87 | + url = "https://type-ruby.github.io" |
| 88 | + } |
| 89 | + ideaVersion { |
| 90 | + sinceBuild = "242" |
| 91 | + untilBuild = "254.*" |
| 92 | + } |
| 93 | + } |
| 94 | + |
| 95 | + signing { |
| 96 | + certificateChain = providers.environmentVariable("CERTIFICATE_CHAIN") |
| 97 | + privateKey = providers.environmentVariable("PRIVATE_KEY") |
| 98 | + password = providers.environmentVariable("PRIVATE_KEY_PASSWORD") |
| 99 | + } |
| 100 | + |
| 101 | + publishing { |
| 102 | + token = providers.environmentVariable("PUBLISH_TOKEN") |
| 103 | + } |
| 104 | +} |
| 105 | + |
| 106 | +kotlin { |
| 107 | + jvmToolchain(21) |
| 108 | +} |
| 109 | + |
| 110 | +tasks { |
| 111 | + buildSearchableOptions { |
| 112 | + enabled = false |
| 113 | + } |
| 114 | + |
| 115 | + test { |
| 116 | + useJUnitPlatform() |
| 117 | + } |
| 118 | +} |
0 commit comments