Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: first iteration #1

Merged
merged 3 commits into from
Oct 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 37 additions & 19 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,24 +1,42 @@
# Compiled class file
*.class
.gradle
build/
!gradle/wrapper/gradle-wrapper.jar
!**/src/main/**/build/
!**/src/test/**/build/

# Log file
*.log
### IntelliJ IDEA ###
.idea/**
.run/**
*.iws
*.iml
*.ipr
out/
!**/src/main/**/out/
!**/src/test/**/out/

# BlueJ files
*.ctxt
### Eclipse ###
.apt_generated
.classpath
.factorypath
.project
.settings
.springBeans
.sts4-cache
bin/
!**/src/main/**/bin/
!**/src/test/**/bin/

# Mobile Tools for Java (J2ME)
.mtj.tmp/
### NetBeans ###
/nbproject/private/
/nbbuild/
/dist/
/nbdist/
/.nb-gradle/

# Package Files #
*.jar
*.war
*.nar
*.ear
*.zip
*.tar.gz
*.rar
### VS Code ###
.vscode/

# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*
replay_pid*
### Mac OS ###
.DS_Store
# Project exclude paths
/.intellijPlatform/
21 changes: 20 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,20 @@
# pit4u
# PIT4U

PIT4U is a Plugin for IntelliJ to help you run mutation testing using [PIT](http://pitest.org).

## Why?

I created this plugin because the [reference plugin](https://github.com/mjedynak/pit-idea-plugin) seems to be abandoned,
and latest version is using deprecated APIs that is causing IntelliJ to freeze and report errors when using it.

## Roadmap

- [x] Create MVP
- [ ] Publish MVP
- [ ] Add context-aware action
- [ ] Fix validations in `Other params` table
- [ ] Parse results and show them in the IDE directly

## Donations

TBD
77 changes: 77 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
import org.jetbrains.intellij.platform.gradle.TestFrameworkType

plugins {
id("java")
id("org.jetbrains.intellij.platform") version "2.1.0"
}

group = "io.github.nahuel92"

repositories {
mavenCentral()

intellijPlatform {
defaultRepositories()
}
}

intellijPlatform {
pluginConfiguration {
version = providers.gradleProperty("pluginVersion")
id = "io.github.nahuel92.pit4u"
name = "PIT4U"
version = "1.0.0"
description = "Plugin that allows you to run PIT mutation tests directly from your IDE"
changeNotes = "notes"
ideaVersion {
sinceBuild.set("232")
untilBuild.set("242.*")
}
}
}

dependencies {
implementation("org.pitest:pitest:1.17.0")
implementation("org.pitest:pitest-junit5-plugin:1.2.1")
implementation("org.pitest:pitest-command-line:1.17.0")
implementation("org.pitest:pitest-entry:1.17.0")
intellijPlatform {
intellijIdeaCommunity("2024.2.3")
bundledPlugin("com.intellij.java")
bundledPlugin("org.jetbrains.idea.maven")
bundledPlugin("com.intellij.gradle")

pluginVerifier()
zipSigner()
instrumentationTools()

testFramework(TestFrameworkType.Platform)
}
}

tasks {
withType<JavaCompile> {
sourceCompatibility = "21"
targetCompatibility = "21"
}

patchPluginXml {
sinceBuild.set("232")
untilBuild.set("242.*")
pluginVersion.set("1.0-SNAPSHOT")
}

signPlugin {
certificateChain.set(System.getenv("CERTIFICATE_CHAIN"))
privateKey.set(System.getenv("PRIVATE_KEY"))
password.set(System.getenv("PRIVATE_KEY_PASSWORD"))
}

publishPlugin {
token.set(System.getenv("PUBLISH_TOKEN"))
}

generateManifest {
version.set("1.0-SNAPSHOT")
}
}
6 changes: 6 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Opt-out flag for bundling Kotlin standard library -> https://jb.gg/intellij-platform-kotlin-stdlib
kotlin.stdlib.default.dependency=false
# Enable Gradle Configuration Cache -> https://docs.gradle.org/current/userguide/configuration_cache.html
org.gradle.configuration-cache=true
# Enable Gradle Build Cache -> https://docs.gradle.org/current/userguide/build_cache.html
org.gradle.caching=true
Binary file added gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
5 changes: 5 additions & 0 deletions gradle/wrapper/gradle-wrapper.properties
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.10-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading