forked from profesorfalken/jPowerShell
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.gradle
More file actions
92 lines (81 loc) · 2.32 KB
/
build.gradle
File metadata and controls
92 lines (81 loc) · 2.32 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
plugins {
id "java"
id "signing"
id "maven-publish"
}
group = 'io.github.autocomplete1'
version = '1.1.0'
description = 'Simple Java API to interact with PowerShell console'
java.sourceCompatibility = JavaVersion.VERSION_21
repositories {
mavenLocal()
maven {
url = uri('https://repo.maven.apache.org/maven2/')
}
}
dependencies {
testImplementation 'junit:junit:4.13.2'
}
test {
// show standard out and standard error of the test JVM(s) on the console
testLogging.showStandardStreams = true
}
publishing {
publications {
maven(MavenPublication) {
from(components.java)
}
}
}
java {
withJavadocJar()
withSourcesJar()
}
artifacts {
archives javadocJar, sourcesJar
}
signing {
sign configurations.archives
sign publishing.publications.maven
}
project.plugins.withType(MavenPublishPlugin).all {
PublishingExtension publishing = project.extensions.getByType(PublishingExtension)
publishing.publications.withType(MavenPublication).all { mavenPublication ->
mavenPublication.pom {
name = "${project.group}:${project.name}"
description = name
url = "https://github.com/AutoComplete1/jPowerShell2"
licenses {
license {
name = "The Apache License, Version 2.0"
url = "https://www.apache.org/licenses/LICENSE-2.0"
}
}
developers {
developer {
id = "autocomplete1"
name = "AutoComplete"
}
}
scm {
connection = "scm:git:https://github.com/AutoComplete1/jPowerShell2"
developerConnection = "scm:git:ssh://github.com/AutoComplete1/jPowerShell2.git"
url = "https://github.com/AutoComplete1/jPowerShell2"
}
}
}
}
publishing {
repositories {
maven {
name = "local"
// change URLs to point to your repos, e.g. http://my.org/repo
def releasesRepoUrl = "$buildDir/repos/releases"
def snapshotsRepoUrl = "$buildDir/repos/snapshots"
url = version.endsWith("SNAPSHOT") ? snapshotsRepoUrl : releasesRepoUrl
}
}
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}