Loading repository data…
Loading repository data…
easymock / repository
Okay, it's pretty easy to instantiate objects in Java through standard reflection. However there are many cases where you need to go beyond what reflection provides. For example, if there's no public constructor, you want to bypass the constructor code, or set final fields. There are numerous clever (but fiddly) approaches to getting around this and this library provides a simple way to get at them. You will find the official site here.
Objenesis is a library dedicated to bypass the constructor when creating an object. On any JVM there is.
You can find the website and user documentation at objenesis.org.
I'm using:
To configure your local workspace:
objenesis-formatting.xml (usable in Eclipse or IntelliJ)There are two different levels of build.
It is a basic compilation of the application.
mvn install
This build will create the source and javadoc jars and run spotbugs.
mvn install -Pfull
brew cask install android-sdk)platform-tools and build-tools using the sdkmanager (sdkmanager "platform-tools" "build-tools")ANDROID_HOME to target the Android SDK (export ANDROID_HOME=$(realpath $(echo "$(dirname $(readlink $(which sdkmanager)))/../..")))ANDROID_HOME to environmental variables (path used to install SDK on previous step)mvn package -Pandroidmvn package -Pbenchmark
cd benchmark
./launch.sh
mvn package -Pwebsite
mvn versions:set -DnewVersion=X.Y -Pallmvn versions:commit -Pall if everything is ok, mvn versions:revert -Pall otherwise<servers>
<server>
<id>ossrh</id>
<username>sonatypeuser</username>
<password>sonatypepassword</password>
</server>
</servers>
mvn versions:display-dependency-updates versions:display-plugin-updates -Pall
mvn wrapper:wrapper
mvn validate license:format -Pall
mvn modernizer:modernizer -Pall
We make sure a build will always create the same result with done from the same sources. It follows these guidelines.
Useful commands:
# Checks that all plugins are compatible
mvn artifact:check-buildplan -Pfull,all
# Build and install the artifact
mvn clean install -Pfull,all
# Build and compare the artifact with the installed one
mvn clean verify artifact:compare -Pfull,all
website/site/content/notes.html You use this code to generate it. If you have more than 100 items, do it again with &page=2# Get the milestone matching the version
version=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout | cut -d'-' -f1)
milestone=$(curl -s "https://api.github.com/repos/easymock/objenesis/milestones" | jq ".[] | select(.title==\"$version\") | .number")
echo "<h1>Version $version ($(date '+%Y-%m-%d'))</h1>"
echo
echo "<ul>"
curl -s "https://api.github.com/repos/easymock/objenesis/issues?milestone=${milestone}&state=all&per_page=100" | jq -r '.[] | " <li>" + .title + " (#" + (.number|tostring) + ")</li>"'
echo "</ul>"
./deploy.shIf something fails, and you need to rollback a bit, the following commands might help:
mvn release:rollback -Pall
git tag -d $version
git push origin :refs/tags/$version
git reset --hard HEAD~2
If you find something went wrong you can drop the staging repository with mvn nexus-staging:drop.
./deploy-website.sh