jdrivesync is a simple command line tool that synchronizes a local file system structure to your Google Drive (and back):
java -jar jdrivesync-0.4.2-jar-with-dependencies.jar -l "/home/siom79"
The website is located at http://siom79.github.io/jdrivesync/.
If you want to contribute, you can fork the project into your github account, create a feature branch and later submit your changes in form of a pull request.
Please format your code according to the Java Conventions
as they are provided by your IDE
(IntelliJ,
Eclipse) with the following changes:
- Line length: 180
- Newline: LF
The sources are build using the JDK (>= 11) and maven (>= 3.9). To build jdrivesync from scratch execute these commands:
git clone https://github.com/siom79/jdrivesync.git
cd jdrivesync
mvn install
After successful compilation you can execute jdrivesync with this command:
java -jar target/jdrivesync-0.4.3-jar-with-dependencies.jar
The deb package is created with the maven plugin jdeb during the build and is located in the target
directory.
Version control follows the guidelines known as gitflow. This means
basically that the master branch is always in a releasable state and that all work is done on feature branches that
are later on merged to the develop
branch.
Integration tests are written with JUnit and reside under src/test/java
. The class names have
to start with IT
in order to distinguish them from normal unit tests. To run the integration tests place a valid authentication
file under src/test/resources/.jdrivesync
and execute them with (as they are not executed during a normal build):
mvn test -Pintegration-test
Please use a separate Google account for these integration tests as they are written to delete and to list all files of the account.
- Set the release version:
mvn versions:set -DnewVersion=<version> mvn versions:commit git add . git commit -m "Version set <version>"
- Create a git tag:
git tag v<version> git push origin --tags
- The release is automatically created by a Github Action
- Set the next SNAPSHOT version:
mvn versions:set -DnewVersion=<version>-SNAPSHOT mvn versions:commit git add . git commit -m "Version set <version>-SNAPSHOT"
- Checkout tag and run site plugin:
cd /tmp
git clone --branch v<verion> https://github.com/siom79/jdrivesync.git
cd jdrivesync
mvn site:site
mvn site:stage
cp -r target/staging $SIOM79_GITHUB_IO_REPO