Skip to content

Latest commit

 

History

History
92 lines (69 loc) · 3.49 KB

CONTRIBUTING.adoc

File metadata and controls

92 lines (69 loc) · 3.49 KB

Contributing

Source-code Setup

Install Java 11

It needs JDK 11 installed in your system. I recommend doing it via SDKMAN. After you install SDKMAN, run sdk list java → Pick Identifier for your favorite java 11 dist → Run sdk install java <Identifier-you-picked> to install Java.

Build with Gradle

This is a simple Gradle project and has its own Gradle wrapper. So nothing to install, run just this command:

./gradlew clean build
💡
You don’t need a local Gradle installation as the gradlew (Gradle wrapper) takes care of everything. But if you wish to install Gradle locally, the recommendation is to do it via SDKMAN. After you install SDKMAN, run sdk install gradle to install Gradle

You can run/debug the existing unit tests or write your own to play with the tool.

Kotlin

  • The code-base is a mix of Java and Kotlin. If you’re a Java developer and new to Kotlin, don’t worry, Kotlin is a JVM language and can be used anywhere Java is used. In fact, it has got the reputation of "Better Java!".

  • A typical Java developer can ramp up on Kotlin in less than a week. These resources can help catalyze your ramp-up:

  • If you use Intellij, Kotlin plugin comes bundled. Similar development aids should be present for other code editors too.

Code Formatting

This repo uses Spotless for formatting files. Please run ./gradlew spotlessApply before check-in to fix any formatting errors.

💡
If you’re on Intellij, replace your kbd:[Cmd+Shift+L] habit with kbd:[Ctrl]-kbd:[Ctrl] and run ./gradlew spotlessApply (Or the respective action if you’re on VS Code/Eclipse). It may be slow for the first run, but subsequent runs should be faster.

Manual publishing

Versioning Strategy

<A>.<B>.<C>

  • A = Broke something on purpose (Breaking API change)

  • B = Profit (Feature / Improvement)

  • C = Broke something by accident (Bug)

Follow the Versioning Strategy to increment version here

  • For SNAPSHOT releases, add a -SNAPSHOT at the end of version number

  • Run this command to publish it to Nexus:

./gradlew publishToSonatype closeAndReleaseSonatypeStagingRepository -Dorg.gradle.parallel=false --no-configuration-cache
  • You can monitor for the new version jar to reflect in Maven Central. It usually takes less than 30 minutes.

Code of Conduct

Please follow our Code of Conduct

License

By contributing your code, you agree to license your contribution under the terms of our project LICENSE and to sign the Salesforce CLA