Skip to content

Commit

Permalink
Update README, LICENSE, and cleanup code/settings (#4)
Browse files Browse the repository at this point in the history
* Update build.gradle for new maven central releases.

* Made private and static variables final

* Updated README and LICENSE. Removed Travis CI yml and README mention.

* Update .gitignore
  • Loading branch information
maximeroussy authored Jan 25, 2022
1 parent 18a06d1 commit cc9bbbf
Show file tree
Hide file tree
Showing 15 changed files with 62 additions and 115 deletions.
26 changes: 3 additions & 23 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,29 +61,9 @@ gradle-app.setting

# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898
# gradle/wrapper/gradle-wrapper.properties
### JetBrains template
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# 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

# IDE
.idea/*
local.properties

# Gradle and Maven with auto-import
Expand Down
1 change: 0 additions & 1 deletion .idea/.name

This file was deleted.

16 changes: 0 additions & 16 deletions .idea/checkstyle-idea.xml

This file was deleted.

2 changes: 0 additions & 2 deletions .idea/invitrode.iml

This file was deleted.

7 changes: 0 additions & 7 deletions .idea/misc.xml

This file was deleted.

2 changes: 0 additions & 2 deletions .idea/modules/Invitrode.iml

This file was deleted.

2 changes: 0 additions & 2 deletions .idea/modules/Invitrode_main.iml

This file was deleted.

2 changes: 0 additions & 2 deletions .idea/modules/invitrode_test.iml

This file was deleted.

6 changes: 0 additions & 6 deletions .idea/vcs.xml

This file was deleted.

1 change: 0 additions & 1 deletion .travis.yml

This file was deleted.

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) 2018 Maxime Roussy
Copyright (c) 2022 Maxime Roussy

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
17 changes: 7 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

A Java/Android library to generate random english pronounceable words based on a collection of constructed bi-grams.

[![MIT License](http://img.shields.io/badge/license-MIT-green.svg)](https://github.com/maximeroussy/invitrode/license.md) ![CI Build](https://travis-ci.com/maximeroussy/invitrode.svg?branch=master) [![GitHub release](https://img.shields.io/github/release/maximeroussy/invitrode.svg)](https://GitHub.com/maximeroussy/invitrode/releases/)
[![MIT License](http://img.shields.io/badge/license-MIT-green.svg)](https://github.com/maximeroussy/invitrode/license.md) [![GitHub release](https://img.shields.io/github/release/maximeroussy/invitrode.svg)](https://GitHub.com/maximeroussy/invitrode/releases/)

## Summary
This is a lightweight and focused library. There's a single class with only a single public method that's accessible.
Expand All @@ -14,7 +14,7 @@ This library can be used in an infinite amount of ways:
- the list goes on...

## Demo
Here's a simple Android app built with the library that demonstrates it's usage:
Here's a simple Android app built with the library that demonstrates its usage:

<p>
<a href="https://github.com/maximeroussy/invitrode/blob/master/android-demo.gif"><img src="/android-demo.gif" align="center" height="500"></a>
Expand All @@ -23,13 +23,13 @@ Here's a simple Android app built with the library that demonstrates it's usage:
This demo app is available on [Google Play](https://play.google.com/store/apps/details?id=com.maximeroussy.invitrodeandroid).

## Download/Install
The library is available through jCenter, which is included in your repositories by default on Android. For a Java
project, make sure you have jCenter added to your repositories.
The library is available through Maven Central, which is included in your repositories by default on Android. For a Java
project, make sure you have `mavenCentral()` added to your repositories.

### Gradle (preferred):

```gradle
compile 'com.maximeroussy.invitrode:invitrode:2.0.1'
implementation 'com.maximeroussy.invitrode:invitrode:2.0.2'
```

### Maven:
Expand All @@ -38,7 +38,7 @@ compile 'com.maximeroussy.invitrode:invitrode:2.0.1'
<dependency>
<groupId>com.maximeroussy.invitrode</groupId>
<artifactId>invitrode</artifactId>
<version>2.0.1</version>
<version>2.0.2</version>
<type>pom</type>
</dependency>
```
Expand All @@ -56,15 +56,12 @@ String myNewWord = generator.newWord(int lengthOfWord);
```

## Inspiration & Credits
Why the name Invitrode? Why make a random word generator? This should suffice:
[https://www.youtube.com/watch?v=FbccrO8qKog](https://www.youtube.com/watch?v=FbccrO8qKog)

Bi-gram source and general concept based on [Scrollback's generate.js](https://github.com/scrollback/scrollback/blob/master/lib/generate.js) & described in [this blog post](https://www.hackerearth.com/notes/random-pronouncable-text-generator/) by Aravind. This is a Java adaptation that will be further developed as a functional and feature rich random word generator.

## License
The MIT License (MIT)

Copyright (c) 2019 Maxime Roussy
Copyright (c) 2022 Maxime Roussy

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
82 changes: 46 additions & 36 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
apply plugin: 'java'
apply plugin: 'java-library'

def versionMajor = 2
def versionMinor = 0
def versionPatch = 2
group = 'com.maximeroussy.invitrode'
version = "${versionMajor}.${versionMinor}.${versionPatch}"

buildscript {
repositories {
mavenCentral()
}
}

apply plugin: 'java'
apply plugin: 'java-library'
apply plugin: 'maven-publish'

sourceCompatibility = 1.8

repositories {
Expand All @@ -36,44 +33,57 @@ task javadocJar(type: Jar, dependsOn: javadoc) {
from 'build/docs/javadoc'
}

def pomConfig = {
licenses {
license {
name 'The MIT License'
url 'https://opensource.org/licenses/MIT'
distribution 'repo'
}
}
developers {
developer {
id 'maximeroussy'
name 'Maxime Roussy'
email 'roussy.maxime@gmail.com'
}
}

scm {
url 'https://github.com/maximeroussy/invitrode'
}
artifacts {
archives javadocJar, sourcesJar
}

apply plugin: 'maven-publish'

publishing {
publications {
mavenJava(MavenPublication) {
from components.java
artifact sourcesJar
groupId = "com.maximeroussy.invitrode"
artifactId = 'invitrode'
version = "${versionMajor}.${versionMinor}.${versionPatch}"
artifact javadocJar
groupId 'com.maximeroussy.invitrode'
artifactId 'invitrode'
version "${versionMajor}.${versionMinor}.${versionPatch}"
artifact sourcesJar
from components.java

pom.withXml {
def root = asNode()
root.appendNode('description', 'A Java library to generate random english pronounceable words.')
root.appendNode('name', 'invitrode')
root.appendNode('url', 'https://github.com/maximeroussy/invitrode')
root.children().last() + pomConfig
pom {
name = 'invitrode'
packaging = 'jar'
description = "A Java library to generate random english pronounceable words."
url = 'https://github.com/maximeroussy/invitrode'

scm {
connection = 'scm:git:git://github.com/maximeroussy/invitrode.git'
developerConnection = 'scm:git:ssh://github.com:maximeroussy/invitrode.git'
url = 'https://github.com/maximeroussy/invitrode/tree/master'
}

licenses {
license {
name = 'The MIT License'
url = 'https://opensource.org/licenses/MIT'
distribution = 'repo'
}
}

developers {
developer {
id = 'maximeroussy'
name = 'Maxime Roussy'
email = 'roussy.maxime@gmail.com'
}
}
}
}
}
}

jar {
into("META-INF/maven/$project.group/$project.name") {
from { generatePomFileForMavenJavaPublication }
rename ".*", "pom.xml"
}
}
3 changes: 1 addition & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#Mon Sep 17 14:11:31 MDT 2018
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.3-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip
Loading

0 comments on commit cc9bbbf

Please sign in to comment.