Skip to content

Commit

Permalink
Moving plugin from gradle-utils complete
Browse files Browse the repository at this point in the history
  • Loading branch information
koneal committed Jun 24, 2015
1 parent 2f7b890 commit 4506b8a
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 29 deletions.
17 changes: 9 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,21 @@
A gradle plugin for creating the .syntastic_javac_config file used by syntastic in VIM.

##### Using the Plugin
```groovy
buildscript {
repositories {
jcenter()
}
dependencies {
classpath group: 'com.scuilion', name: 'syntastic', version: '0.+'
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath "com.scuilion.syntastic:gradle-syntastic-plugin:0.3.2"
}
}

apply plugin: 'syntastic'
apply plugin: "com.scuilion.syntastic"
```
Task
* createSyntastic - for working in vim with the [syntastic](https://github.com/scrooloose/syntastic) syntastic checking plugin.
This plugin attaches the createSyntastic plugin to 'compileJava' and 'compileGroovy' tasks.
This plugin attaches the createSyntastic plugin to 'compileJava' and 'compileGroovy' tasks. It must be applied after your configure you project.
11 changes: 8 additions & 3 deletions bintray.gradle
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
bintray {
user = bintrayUser
key = bintrayKey
publications = ['mavenStuff']
publications = ['maven']

dryRun = false //Whether to run this as dry-run, without deploying
publish = false //If version should be auto published after an upload
pkg {
desc = pluginDescription
repo = 'maven'
name = 'gradle-syntastic-plugin'
name = artifactId
licenses = ['MIT']
labels = ['gradle', 'utilities']
labels = artifactTags.tokenize(' ')
vcsUrl = syntasticVcsUrl
version {
name = project.version
}
}

}
29 changes: 16 additions & 13 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,54 +2,57 @@ buildscript {
repositories {
mavenLocal()
jcenter()
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
//classpath group: 'com.scuilion.gradle', name: 'utils', version: '0.5' //new BigDecimal(version) - new BigDecimal('0.1')
classpath "com.gradle.publish:plugin-publish-plugin:0.9.0"
}
}


plugins {
id "com.jfrog.bintray" version "1.2"
}

apply from: 'bintray.gradle'
apply plugin: 'com.jfrog.bintray'
apply plugin: "com.gradle.plugin-publish"
apply plugin: 'java-gradle-plugin'

apply plugin: 'maven-publish'
apply plugin: 'groovy'
apply plugin: 'maven-publish'
apply plugin: 'com.jfrog.bintray'

apply from: 'check.gradle'
apply from: 'publishPlugin.gradle'

repositories {
mavenCentral()
}

dependencies {
compile gradleApi()
compile localGroovy()
compile 'org.apache.commons:commons-lang3:3.4'

testCompile 'junit:junit:4.12'
}

task sourceJar(type: Jar) {
from sourceSets.main.groovy
from sourceSets.main.resources
task sourceJar(type: Jar, dependsOn:classes) {
classifier = 'sources'
from sourceSets.main.allSource
}

artifacts {
archives jar, sourceJar
archives sourceJar
}

publishing {
publications {
maven(MavenPublication) {
groupId 'com.scuilion'
artifactId 'syntastic'
groupId group
artifactId artifactId
version version
from components.java
artifact sourceJar
}
}
}
Expand Down Expand Up @@ -87,13 +90,13 @@ task integrationTest(type:Test){

getReports().getHtml().setDestination(new File("$project.reporting.baseDir", 'integrationTest'))
getReports().getJunitXml().setDestination(new File("$project.buildDir", 'integration-results'))
//attachTo test
dependsOn publishToMavenLocal
mustRunAfter test
}

task wrapper(type: Wrapper) {
gradleVersion = '2.4'
}
apply from: 'bintray.gradle'

//apply plugin: 'syntastic-plugin'
13 changes: 8 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
version=0.1
#manually specify key and user in the bintray.gradle
#file. I don't know why. Figure it out later.
bintrayUser=
bintrayKey=
group=com.scuilion.syntastic
version=0.3.2
artifactTags=utility syntastic
pluginDescription=Integrate syntastic with your gradle projects.
syntasticVcsUrl=https\://github.com/scuilion/gradle-syntastic-plugin.git
artifactId=gradle-syntastic-plugin
gradle.publish.key=
gradle.publish.secret=
18 changes: 18 additions & 0 deletions publishPlugin.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
pluginBundle {
website = 'scuilion.wordpress.com'
vcsUrl = syntasticVcsUrl
tags = artifactTags.tokenize(' ')
plugins {
syntasticPlugin {
vcsUrl = syntasticVcsUrl
id = group
displayName = 'Syntastic'
description = pluginDescription
}
}
mavenCoordinates {
groupId = 'com.scuilion.syntastic'
artifactId = artifactId
version = version
}
}

0 comments on commit 4506b8a

Please sign in to comment.