Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/CI build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ jobs:
uses: actions/checkout@v2

# Setup the jdk using version 11 of adoptOpenJDK
- name: Setup java 11 using adoptOpenJDK
- name: Setup java 11 using Adoptium Temurin
uses: actions/setup-java@v2
with:
distribution: adopt
java-version: 11
distribution: 'temurin'
java-version: '11'

# Build the project using
# - clean : clean up the workspace
Expand Down
51 changes: 28 additions & 23 deletions .github/workflows/CI release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,25 @@ jobs:
- name: Checkout
uses: actions/checkout@v2

# Setup the jdk using version 11 of adoptOpenJDK
- name: Java setup
# Install the GPG secret key
- name: Step 2 - Import GPG Key
run: |
echo "${{ secrets.GPG_PUBLIC_KEY }}" | gpg --import
echo "${{ secrets.GPG_SECRET_KEY }}" | gpg --import --no-tty --batch --yes
env:
GPG_PUBLIC_KEY: ${{ secrets.GPG_PUBLIC_KEY }}
GPG_SECRET_KEY: ${{ secrets.GPG_SECRET_KEY }}

# Set up the jdk using version 11 of Adoptium Temurin
- name: Setup java 11 using Adoptium Temurin
uses: actions/setup-java@v2
with:
distribution: adopt
java-version: 11
distribution: 'temurin'
java-version: '11'
server-id: central
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }}
gpg-private-key: ${{ secrets.GPG_SECRET_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE

# Configure git user in order to sign release with OrbisGIS user.
Expand All @@ -34,15 +43,10 @@ jobs:
git config user.email "info@orbisgis.org"
git config user.name OrbisGIS

#Install the GPG secret key
- name: Install gpg secret key
run: |
cat <(echo -e "${{ secrets.OSSRH_GPG_SECRET_KEY }}") | gpg --batch --import
gpg --list-secret-keys --keyid-format LONG

# Test build
- name: Build test
run: mvn -ntp clean validate compile test javadoc:test-javadoc
run: mvn -ntp clean validate compile test javadoc:test-javadoc javadoc:jar

# Create the release :
# - move from Snapshot version to Release
Expand All @@ -60,34 +64,33 @@ jobs:
release:prepare release:perform \
-Dusername=$GITHUB_ACTOR -Dpassword=$GITHUB_TOKEN ${VERSION:+"-DdevelopmentVersion="$VERSION"-SNAPSHOT"}
env:
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.OSSRH_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.OSSRH_GPG_PASSWORD }}
MAVEN_USERNAME: ${{ secrets.MVN_CENTRAL_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.MVN_CENTRAL_PASSWORD }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}

# Export the last git tag into env.
- name: Export env values
run: echo "GIT_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)" >> $GITHUB_ENV

# Make the Github release from the last created tag. Write in its body the content of the changelog file.
- name: Make Github release
uses: ncipollo/release-action@v1
# Make the github release from the last created tag. Write in its body the content of the changelog file.
- name: Make github release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
with:
tag: ${{ env.GIT_TAG }}
name: ${{ env.GIT_TAG }}
bodyFile: "docs/CHANGELOG.md"
tag_name: ${{ env.GIT_TAG }}
release_name: ${{ env.GIT_TAG }}
body_path: docs/CHANGELOG.md
draft: false
prerelease: false

# Clear the changelog file and add its header
- name: Clear changelog
run: |
echo "# Changelog for v$( mvn help:evaluate -Dexpression=project.version | sed -n -e '/^\[.*\]/ !{ /^[0-9]/ { p; q } }' | cut -d- -f1)" > docs/CHANGELOG.md
echo "## Changelog for v$( mvn help:evaluate -Dexpression=project.version | sed -n -e '/^\[.*\]/ !{ /^[0-9]/ { p; q } }' | cut -d- -f1)" > docs/CHANGELOG.md
git commit -a -m "Empty changelog."
git push origin master


# If the version change is a major or minor, create a branch from the previous tag for future revisions.
- name: Branch fork
run: |
Expand All @@ -101,5 +104,7 @@ jobs:
echo "Minor or Major change"
BRANCH="${SPLIT0[0]}.${SPLIT0[1]}.X"
git checkout -b "$BRANCH" "v${GIT_TAG}"
mvn versions:set -DnewVersion="${SPLIT0[0]}.${SPLIT0[1]}.$((${SPLIT0[2]}+1))-SNAPSHOT"
git commit -a -m "Set next version."
git push -u origin "$BRANCH"
fi
31 changes: 17 additions & 14 deletions .github/workflows/CI snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,28 +19,31 @@ jobs:
- name: Checkout
uses: actions/checkout@v2

# Setup the jdk using version 11 of adoptOpenJDK
- name: Java setup
# Install the GPG secret key
- name: Step 2 - Import GPG Key
run: |
echo "${{ secrets.GPG_PUBLIC_KEY }}" | gpg --import
echo "${{ secrets.GPG_SECRET_KEY }}" | gpg --import --no-tty --batch --yes
env:
GPG_PUBLIC_KEY: ${{ secrets.GPG_PUBLIC_KEY }}
GPG_SECRET_KEY: ${{ secrets.GPG_SECRET_KEY }}

# Set up the jdk using version 11 of Adoptium Temurin
- name: Setup java 11 using Adoptium Temurin
uses: actions/setup-java@v2
with:
distribution: adopt
java-version: 11
distribution: 'temurin'
java-version: '11'
server-id: central
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }}
gpg-private-key: ${{ secrets.GPG_SECRET_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE

# Install the GPG secret key
- name: Install gpg secret key
run: |
cat <(echo -e "${{ secrets.OSSRH_GPG_SECRET_KEY }}") | gpg --batch --import
gpg --list-secret-keys --keyid-format LONG

# Deploy the snapshot
- name: Deploy
run: mvn deploy -ntp --batch-mode
env:
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.OSSRH_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.OSSRH_GPG_PASSWORD }}
MAVEN_USERNAME: ${{ secrets.MVN_CENTRAL_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.MVN_CENTRAL_PASSWORD }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
1 change: 1 addition & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Changelog for v0.5.1

- Update to central portal
- Fix doc
3 changes: 2 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
<maven-jar-version>3.3.0</maven-jar-version>
<maven-javadoc-version>3.3.1</maven-javadoc-version>
<maven-source-version>3.2.1</maven-source-version>
<maven-release-version>3.2.2</maven-release-version>
<maven-release-version>3.0.1</maven-release-version>
<maven-surefire-version>3.2.2</maven-surefire-version>
<version-maven-version>2.16.0</version-maven-version>
</properties>
Expand Down Expand Up @@ -115,6 +115,7 @@
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>${maven-bundle-version}</version>
<extensions>true</extensions>
<configuration>
<instructions>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ protected void init(VWCent startNode) {
*
* @param startNode
* @param u Vertex u.
* @return
*/
@Override
protected boolean preRelaxStep(VWCent startNode, VWCent u) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,8 +141,6 @@ public GraphCreator(String csvFile,
*
* @return The graph.
*
* @throws FileNotFoundException
* @throws NoSuchMethodException
*/
public KeyedGraph<V, E> loadGraph()
throws FileNotFoundException, NoSuchMethodException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ public interface ProgressMonitor {
* Returns {@code true} if the process is canceled and should end as quickly
* as possible.
*
* @return
*/
boolean isCancelled();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ public void testU() throws Exception {
*
* @return Distance matrix
*
* @throws Exception
*/
public Double[][] actualDistances(KeyedGraph<VDijkstra, Edge> g)
throws Exception {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ public class StrahlerTest {
/**
* Tests the {@link #prepareTree()} tree.
*
* @throws IllegalArgumentException
*/
@Test
public void testStrahler() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -381,8 +381,8 @@ protected void checkCloseness(
/**
* Prints the amount of time graph analysis took.
*
* @param time
* @param analysisType
* @param time The time.
* @param analysisType analysis type
*/
protected void printTime(double time, String analysisType) {
LOGGER.info("({} ms) {} {} Graph Analysis",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ public abstract class GraphPrep<V extends VId, E extends Edge<E>> {
*
* @return The original weighted directed graph
*
* @throws NoSuchMethodException
*/
public abstract DirectedWeightedPseudoG<V, E> weightedDirected()
throws NoSuchMethodException;
Expand All @@ -88,7 +87,6 @@ public abstract DirectedWeightedPseudoG<V, E> weightedDirected()
*
* @return A weighted edge-reversed view
*
* @throws NoSuchMethodException
*/
public WeightedEdgeReversedG<V, E> weightedReversed() throws
NoSuchMethodException {
Expand All @@ -100,7 +98,6 @@ public WeightedEdgeReversedG<V, E> weightedReversed() throws
*
* @return A weighted undirected view
*
* @throws NoSuchMethodException
*/
public UndirectedG<V, E> weightedUndirected() throws
NoSuchMethodException {
Expand All @@ -112,7 +109,6 @@ public UndirectedG<V, E> weightedUndirected() throws
*
* @return An unweighted directed view
*
* @throws NoSuchMethodException
*/
public DirectedG<V, E> directed()
throws NoSuchMethodException {
Expand All @@ -124,7 +120,6 @@ public DirectedG<V, E> directed()
*
* @return An unweighted edge-reversed view
*
* @throws NoSuchMethodException
*/
public DirectedG<V, E> reversed()
throws NoSuchMethodException {
Expand Down