Skip to content

Commit

Permalink
GH-1869 Replace NpxTask with NpmTask
Browse files Browse the repository at this point in the history
  • Loading branch information
dzikoysk committed Jul 1, 2023
1 parent 3d6c3fd commit d4d14b8
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions reposilite-frontend/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,19 @@
* limitations under the License.
*/

import com.github.gradle.node.npm.task.NpmTask
import com.github.gradle.node.npm.task.NpxTask

plugins {
id("com.github.node-gradle.node") version "3.2.1"
}

val lintTask = tasks.register<NpxTask>("lintFrontend") {
command.set("eslint")
node {

}

val lintTask = tasks.register<NpmTask>("lintFrontend") {
// command.set("eslint")
args.set(listOf("src/**"))
dependsOn(tasks.npmInstall)
inputs.dir("src")
Expand All @@ -30,8 +35,8 @@ val lintTask = tasks.register<NpxTask>("lintFrontend") {
outputs.upToDateWhen { true }
}

val buildTask = tasks.register<NpxTask>("buildFrontend") {
command.set("vite")
val buildTask = tasks.register<NpmTask>("buildFrontend") {
// command.set("vite")
args.set(listOf("build"))
dependsOn(tasks.npmInstall, lintTask)
inputs.dir(project.fileTree("src"))
Expand Down

0 comments on commit d4d14b8

Please sign in to comment.