Skip to content

Commit d1323a4

Browse files
committed
wip
1 parent 115a12e commit d1323a4

File tree

4 files changed

+9
-3
lines changed

4 files changed

+9
-3
lines changed

build.gradle.kts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,15 @@ apply(from = "gradle/copyBinary.gradle.kts")
4444

4545
tasks.named<ProcessResources>("processResources") {
4646
dependsOn("copyBinary")
47+
dependsOn("copyTypeshed")
4748
}
4849
tasks.buildPlugin {
4950
dependsOn("copyBinary")
51+
dependsOn("copyTypeshed")
5052
}
5153
tasks.named("runIde") {
5254
dependsOn("copyBinary")
55+
dependsOn("copyTypeshed")
5356
}
5457

5558
// Configure IntelliJ Platform Gradle Plugin - read more: https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin-extension.html

build_all.sh

100644100755
File mode changed.

gradle/copyBinary.gradle.kts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,15 @@ tasks.register<Copy>("copyBinary") {
1515

1616
from("odools-binaries/$targetOs")
1717
into("src/main/resources/bin/$targetOs")
18-
include("**/*")
1918

20-
if (!targetOs.startsWith("win")) {
19+
if (!targetOs.startsWith("win")) { //TODO is it executed before or after copy?
2120
fileTree("src/main/resources/bin/$targetOs").files.forEach {
2221
it.setExecutable(true, false)
2322
}
2423
}
24+
}
2525

26+
tasks.register<Copy>("copyTypeshed") {
2627
val hashFile = file(".git/modules/typeshed/refs/heads/main")
2728
if (hashFile.exists()) {
2829
val commitHash = hashFile.readText().trim()
@@ -39,5 +40,4 @@ tasks.register<Copy>("copyBinary") {
3940

4041
from("typeshed")
4142
into("src/main/resources/typeshed")
42-
include("**/*")
4343
}

src/main/kotlin/com/odoo/odools/OdooLSInstallationProjectActivity.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,9 @@ class OdooLSInstallationProjectActivity : ProjectActivity, DumbAware {
196196
(!Files.exists(Paths.get(targetLocation, "odoo_ls_server.pdb")))) {
197197
ressourceToInstallPath("bin/${targetOs}/odoo_ls_server.pdb", Paths.get(targetLocation, "odoo_ls_server.pdb"))
198198
}
199+
if (!SystemInfo.isWindows) {
200+
Paths.get(targetLocation, exeName).toFile().setExecutable(true, false)
201+
}
199202
}
200203
if (!Files.exists(Paths.get(targetLocation, "typeshed")) && isTypeshedOutDated(Paths.get(targetLocation, "typeshed"))) {
201204
val file = Paths.get(targetLocation, "typeshed").toFile()

0 commit comments

Comments
 (0)