From 45ccd86dd4d22576dc492085f791e47e9ac5a839 Mon Sep 17 00:00:00 2001 From: michaelangeloio Date: Fri, 5 Jan 2024 10:50:52 -0500 Subject: [PATCH] fix: adjust readme to adhere to jetbrains marketplace guidelines --- README.md | 10 ++++++---- jetbrains/build.gradle.kts | 16 +++++++++++++--- 2 files changed, 19 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 052abbc..851eb91 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ - +

@@ -8,10 +8,12 @@ TypeScript Build Status

+ # Well, Does it Throw? TLDR; This is a *blazingly* fast **lsp server** to find *throw statements* in your javascript code. It's written in Rust and based on [SWC](https://swc.rs/) 🔥. It works for most ECMAScript files, such as `.ts`, `.js`, `.tsx` and `.jsx`. + ### Check it out in action: @@ -21,7 +23,7 @@ Also supports **call expressions**: ![demo](./assets/calltothrow.gif) - + ## Why? Maybe you're working on a large codebase riddled with throw statements everywhere, and you want a better control flow. Or perhaps you're just curious about how many throw statements you have in your codebase. This simple tool can help you with that. @@ -38,7 +40,7 @@ Untyped `throw` statements can be a pain for those who come from languages like | VsCode | [Marketplace](https://marketplace.visualstudio.com/items?itemName=michaelangeloio.does-it-throw-vscode) | | Neovim | [Neovim Installation Docs](https://github.com/michaelangeloio/does-it-throw/blob/main/docs/neovim.md) | | LSP Server | [NPM](https://www.npmjs.com/package/does-it-throw-lsp) | -| JetBrains | Coming soon... | +| JetBrains | [Marketplace](https://plugins.jetbrains.com/plugin/23434-does-it-throw-?noRedirect=true) | > This extension is built with security in mind. It doesn't send any data to any third party servers. All publishes are done via a signed immutable commit from the [CI pipeline](https://github.com/michaelangeloio/does-it-throw/actions/workflows/release-vsix.yaml). @@ -70,4 +72,4 @@ Please use the GitHub discussions tab to provide feedback and suggestions. Thank ## License MIT - See [LICENSE](https://github.com/michaelangeloio/does-it-throw/blob/main/LICENSE.txt) for more information. - \ No newline at end of file + \ No newline at end of file diff --git a/jetbrains/build.gradle.kts b/jetbrains/build.gradle.kts index 0dd1b58..0bff9b5 100644 --- a/jetbrains/build.gradle.kts +++ b/jetbrains/build.gradle.kts @@ -100,11 +100,11 @@ tasks { untilBuild.set("240.*") // Extract the section from README.md and provide for the plugin's manifest - val readMe = layout.projectDirectory.file(file("${project.projectDir}/../server/README.md").path) + val readMe = layout.projectDirectory.file(file("${project.projectDir}/../README.md").path) println("readMe sourceDir: $readMe") pluginDescription = providers.fileContents(readMe).asText.map { - val start = "" - val end = "" + val start = "" + val end = "" with (it.lines()) { if (!containsAll(listOf(start, end))) { @@ -112,6 +112,16 @@ tasks { } subList(indexOf(start) + 1, indexOf(end)).joinToString("\n").let(::markdownToHTML) } + + val start2 = "" + val end2 = "" + + with (it.lines()) { + if (!containsAll(listOf(start2, end2))) { + throw GradleException("Plugin description section not found in README.md:\n$start2 ... $end2") + } + subList(indexOf(start2) + 1, indexOf(end2)).joinToString("\n").let(::markdownToHTML) + } } val changelog = project.changelog // local variable for configuration cache compatibility