Skip to content

Commit

Permalink
Merge pull request #29 from alexanderwe/develop
Browse files Browse the repository at this point in the history
Switch to Gradle
  • Loading branch information
alexanderwe authored Jul 7, 2018
2 parents fc0f686 + bf9f117 commit 46db04a
Show file tree
Hide file tree
Showing 15 changed files with 703 additions and 518 deletions.
153 changes: 125 additions & 28 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,35 +1,132 @@
# Created by https://www.gitignore.io/api/macos,maven,gradle,intellij

### Intellij ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

.idea

# User-specific stuff
.idea/**/workspace.xml
.idea/**/tasks.xml
.idea/**/usage.statistics.xml
.idea/**/dictionaries
.idea/**/shelf

# Sensitive or high-churn files
.idea/**/dataSources/
.idea/**/dataSources.ids
.idea/**/dataSources.local.xml
.idea/**/sqlDataSources.xml
.idea/**/dynamic.xml
.idea/**/uiDesigner.xml
.idea/**/dbnavigator.xml

# Gradle
.idea/**/gradle.xml
.idea/**/libraries
gradle.properties

# CMake
cmake-build-*/

# Mongo Explorer plugin
.idea/**/mongoSettings.xml

# File-based project format
*.iws

# IntelliJ
out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Cursive Clojure plugin
.idea/replstate.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

# Editor-based Rest Client
.idea/httpRequests

### Intellij Patch ###
# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721

*.iml
modules.xml
.idea/misc.xml
*.ipr
*.iws
.idea/

# Eclipse
.settings
.classpath
.project
.metadata
*.launch
.metadata
bin/
tmp/
*.tmp
*.bak
*.swp
*~.nib

# packages
*.class
*.jar
*.war
*.ear

# maven
target/

# Mac
# Sonarlint plugin
.idea/sonarlint

### macOS ###
# General
.DS_Store
.AppleDouble
.LSOverride

# Icon must end with two \r
Icon

# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

### Maven ###
target/
pom.xml.tag
pom.xml.releaseBackup
pom.xml.versionsBackup
pom.xml.next
release.properties
dependency-reduced-pom.xml
buildNumber.properties
.mvn/timing.properties
.mvn/wrapper/maven-wrapper.jar

### Gradle ###
.gradle
/build/

# Ignore Gradle GUI config
gradle-app.setting

# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored)
!gradle-wrapper.jar

# Cache of project
.gradletasknamecache

# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898
# gradle/wrapper/gradle-wrapper.properties


# End of https://www.gitignore.io/api/macos,maven,gradle,intellij


# Project
Test.java
### Project specific ###
src/test/*
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# The MIT License (MIT)

Copyright (c) 2015 - 2017 Alexander Weiß
Copyright (c) 2015 - 2018 Alexander Weiß

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
18 changes: 12 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,6 @@ Simple api for accessing Mailchimp - Work in progess

[![GitHub license](https://img.shields.io/badge/license-MIT-lightgrey.svg)](https://raw.githubusercontent.com/gr4h4n/bananaj/master/LICENSE.md)

[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.github.alexanderwe/bananaj/badge.svg)](https://maven-badges.herokuapp.com/maven-central/com.github.alexanderwe/bananaj)




# Introduction

bananaj provides an Java wrapper for the MailChimp API 3.0. It is possible access your MailChimp data through Java.
Expand All @@ -22,9 +17,20 @@ Add this dependency to your pom.xml to use **bananaj** in your project.
<dependency>
<groupId>com.github.alexanderwe</groupId>
<artifactId>bananaj</artifactId>
<version>0.5.0</version>
<version>0.5.1</version>
</dependency>
```
or with Gradle

```
repositories {
maven { url "http://repo.maven.apache.org/maven2" }
}
dependencies {
compile group: 'com.github.alexanderwe', name: 'bananaj', version: '0.5.1'
}
```

## MailChimpObject class
Most of the com.github.alexanderwe.bananaj.model classes extend the MailChimpObject class.They are immutable, to prevent asynchronous data between the client and the MailChimp server.
Expand Down
95 changes: 95 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
apply plugin: "java"
apply plugin: "maven"
apply plugin: "maven-publish"
apply plugin: 'signing'

group = 'com.github.alexanderwe'
version = '0.5.1'

description = 'A simple MailChimp API wrapper written in Java'

sourceCompatibility = 1.8
targetCompatibility = 1.8

tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}

repositories {
maven { url "http://repo.maven.apache.org/maven2" }
}

dependencies {
compile group: 'commons-codec', name: 'commons-codec', version: '1.11'
compile group: 'net.sourceforge.jexcelapi', name: 'jxl', version: '2.6.12'
compile group: 'org.json', name: 'json', version: '20180130'
compile group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.5'
}

task javadocJar(type: Jar) {
classifier = 'javadoc'
from javadoc
}

task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
}

task fatJar(type: Jar) {
baseName = 'bananaj'
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}

publishing {
publications {
mavenJava(MavenPublication) {
from components.java

artifact javadocJar
artifact sourcesJar

pom {
name = 'bananaj'
description = 'A simple MailChimp API wrapper written in Java'
url = 'https://github.com/alexanderwe/bananaj'
licenses {
license {
name = 'MIT'
url = 'https://raw.githubusercontent.com/alexanderwe/bananaj/master/LICENSE.md'
}
}
developers {
developer {
name = 'Alexander Weiß'
email = 'https://www.github.com/alexanderwe'
}
}
scm {
connection = 'scm:git:git://github.com/alexanderwe/bananaj.git'
developerConnection = 'scm:git:git://github.com/alexanderwe/bananaj.git'
url = 'https://github.com/alexanderwe/bananaj'
}
issueManagement {
url = 'https://github.com/alexanderwe/bananaj/issues'
system = 'GitHub'
}
}
}
}
repositories {
maven {
url 'https://oss.sonatype.org/service/local/staging/deploy/maven2/'
credentials {
username ossrhUsername
password ossrhPassword
}
}
}
}

signing {
sign publishing.publications.mavenJava
}

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
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.3.1-bin.zip
Loading

0 comments on commit 46db04a

Please sign in to comment.