Skip to content

Commit

Permalink
Merge commit 'ae7cf1f13d1527b5d031c9162a80bc44497b00ba' into iot
Browse files Browse the repository at this point in the history
# Conflicts:
#	pom.xml
#	src/main/java/org/ecocean/Encounter.java
#	src/main/java/org/ecocean/LocationID.java
#	src/main/java/org/ecocean/Shepherd.java
#	src/main/java/org/ecocean/Util.java
#	src/main/java/org/ecocean/YouTube.java
#	src/main/java/org/ecocean/servlet/EncounterForm.java
#	src/main/java/org/ecocean/servlet/StripePayment.java
#	src/main/java/org/ecocean/servlet/importer/IndocetStandardImport.java
#	src/main/resources/bundles/commonConfiguration.properties
#	src/main/resources/bundles/contexts.properties
#	src/main/resources/bundles/de/allsharks.properties
#	src/main/resources/bundles/de/encounters.properties
#	src/main/resources/bundles/de/welcome.properties
#	src/main/resources/bundles/en/header.properties
#	src/main/resources/bundles/en/individuals.properties
#	src/main/resources/bundles/en/submit.properties
#	src/main/resources/bundles/es/allsharks.properties
#	src/main/resources/bundles/es/commonConfigurationLabels.properties
#	src/main/resources/bundles/es/individualSearchResultsAnalysis.properties
#	src/main/resources/bundles/es/submit.properties
#	src/main/resources/bundles/fr/overview.properties
#	src/main/resources/bundles/fr/welcome.properties
#	src/main/resources/bundles/locationID.json
#	src/main/resources/emails/en/adoptionConfirmation.html
#	src/main/resources/emails/en/adoptionSpotting.html
#	src/main/resources/emails/en/collaborationInvite.html
#	src/main/resources/emails/en/individualAddEncounter.html
#	src/main/resources/emails/en/individualCreate.html
#	src/main/resources/emails/en/individualUpdate.html
#	src/main/resources/emails/en/newSubmission.html
#	src/main/resources/emails/en/passwordReset.html
#	src/main/resources/emails/foundation-emails/src/pages/adoptionConfirmation.html
#	src/main/resources/emails/foundation-emails/src/pages/adoptionSpotting.html
#	src/main/resources/emails/foundation-emails/src/pages/individualAddEncounter.html
#	src/main/resources/emails/foundation-emails/src/partials/adopt-an-animal.html
#	src/main/resources/emails/old emails/encounterDataUpdate.html
#	src/main/resources/emails/old emails/individualAddEncounter.html
#	src/main/resources/emails/old emails/individualCreate.html
#	src/main/resources/emails/old emails/individualDataUpdate.html
#	src/main/resources/emails/old emails/individualUpdate.html
#	src/main/resources/emails/old emails/newSubmission.html
#	src/main/webapp/WEB-INF/web.xml
#	src/main/webapp/adoptananimal.jsp
#	src/main/webapp/contactus.jsp
#	src/main/webapp/encounters/encounter.jsp
#	src/main/webapp/header.jsp
#	src/main/webapp/index.jsp
#	src/main/webapp/oneTimeDonation.jsp
#	src/main/webapp/photographing.jsp
#	src/main/webapp/userAgreement.jsp
  • Loading branch information
holmbergius committed Jan 23, 2025
2 parents 317fe76 + ae7cf1f commit 5c176ac
Show file tree
Hide file tree
Showing 727 changed files with 37,344 additions and 36,350 deletions.
14 changes: 14 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# These are supported funding model platforms

github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
polar: # Replace with a single Polar username
buy_me_a_coffee: # Replace with a single Buy Me a Coffee username
custom: ['https://secure.givelively.org/donate/conservation-x-labs-inc/wild-me']
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
name: Feature request
name: New Idea
about: Suggest an idea for this project
title: ''
labels: enhancement
labels: 'ideas'
assignees: ''

---

**Is your feature request related to a problem? Please describe.**
**Is your idea related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
Expand Down
15 changes: 7 additions & 8 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
[Plain-text summary description of the solution]
[Plain-text summary description of the solution. Include any class updates, new or edited functions, significant changes to UX, etc]

PR fixes #[REPLACE WITH ISSUE NUMBER]

**Changes**
- [bullet list include any model updates]
- [new or edited functions]
- [significant changes to UX]
- [design decisions, especially if architectural patterns are new/altered]
- [can use text, screenshots, or files]
- [a callout of any ##TODO or ##FIXMEs found/created as part of the fix]
**Before you Submit!**
* Is all the text internationalized?
* If you made a change to the header, did you update the react, jsp, and html?
* Are all depedencies at a locked version?
* Did you adhere to [best practices](https://wildbook.docs.wildme.org/contribute/code-guide.html)?
* Is there a quick [unit test](https://wildbook.docs.wildme.org/contribute/tests.html) you can add?
98 changes: 98 additions & 0 deletions .github/workflows/codecov-report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
name: CodCov, Run Backend and Frontend Tests

on:
push:
branches:
- '**'

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

# Set up Java for backend tests
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '8'

# Set up Node.js for frontend tests
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '16'

# Install dependencies for backend
- name: Install backend dependencies
run: |
#cd src/test
mvn clean install
mkdir -p src/surefire-reports
mkdir -p frontend/coverage
# Run backend tests with coverage
- name: Run backend tests
run: mvn test -e
working-directory: ./
continue-on-error: true

# Install dependencies for frontend
- name: Install frontend dependencies
run: |
cd frontend
npm install
# Run frontend tests with coverage
- name: Run frontend tests
run: npm run test --coverage
working-directory: frontend
continue-on-error: true

# Upload test results and coverage
- name: Upload coverage results
uses: actions/upload-artifact@v3
with:
name: test-results
path: |
target/surefire-reports
frontend/coverage
# List coverage files
- name: Verify coverage files
run: |
echo "Checking backend coverage files..."
ls -l target/site/jacoco/ || echo "No backend coverage files found"
echo "Checking frontend coverage files..."
ls -l frontend/coverage/ || echo "No frontend coverage files found"
# Upload to Codecov
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }} # Add Codecov token as a secret in GitHub
files: |
target/site/jacoco/jacoco.xml
frontend/coverage/lcov.info
flags: backend,frontend
name: codecov-coverage-report
fail_ci_if_error: false # Does not block merge if there’s an error

- name: List files
run: |
#cd src/test
ls -l target/surefire-reports
ls -l frontend/coverage
# Display test coverage in the summary (optional)
- name: Display test coverage summary
run: |
echo "Backend Test Results:"
cat target/surefire-reports/*.txt || true
echo "Frontend Test Coverage Summary:"
cat frontend/coverage/*.* || true
42 changes: 42 additions & 0 deletions .github/workflows/dev-maven-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Development Build

on:
push:
branches:
- main
tags-ignore:
- v*
jobs:
build:
name: Maven build and deploy
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 8*
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 8

- name: Build with Maven
run: |
mvn dependency:resolve -B -U
mvn clean install -DskipTests -Dmaven.javadoc.skip=true -B
mvn -B package --file pom.xml
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: wildmeorg
password: ${{ secrets.WBIA_WILDMEBOT_DOCKER_HUB_TOKEN }}

- name: Build Docker image
run: |
docker build -t wildme/wildbook:main -f devops/development/Dockerfile devops/development/
- name: Push Docker image
run: |
docker push wildme/wildbook:main
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
name: Maven build and package

on: push
name: Maven build and package for main

on:
push:
branches:
- main
- 'releases/**'
tags:
- 'v**'
release:
types: [created]
jobs:
build:
name: Maven build and deploy
Expand All @@ -10,10 +17,11 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up JDK 1.8
uses: actions/setup-java@v1
- name: Set up JDK 8*
uses: actions/setup-java@v4
with:
java-version: 1.8
distribution: 'zulu'
java-version: 8

- name: Build with Maven
run: |
Expand Down
37 changes: 0 additions & 37 deletions .github/workflows/nightly.yml

This file was deleted.

41 changes: 41 additions & 0 deletions .github/workflows/release-maven-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Production Build

on:
release:
types: [published]


jobs:
build:
name: Maven build , deploy and release
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 8*
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 8

- name: Build with Maven
run: |
mvn dependency:resolve -B -U
mvn clean install -DskipTests -Dmaven.javadoc.skip=true -B
mvn -B package --file pom.xml
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: wildmeorg
password: ${{ secrets.WBIA_WILDMEBOT_DOCKER_HUB_TOKEN }}

- name: Build Docker image
run: |
docker build -t wildme/wildbook:${{ github.event.release.tag_name }} -f devops/deploy/Dockerfile devops/deploy/
- name: Push Docker image
run: |
docker push wildme/wildbook:${{ github.event.release.tag_name }}
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ src/main/caribwhale_data_dir
/node_modules
.vscode/
*.swp
/src/jsp/

src/main/webapp/javascript/dev/MarkedIndividual.json
src/main/webapp/javascript/dev/Relationship.json
Expand All @@ -43,3 +44,5 @@ catalina.base_IS_UNDEFINED
/frontend/.env
/frontend/build
/frontend/.env
/frontend/src/serviceWorkerRegistration.js
/frontend/src/serviceWorker.js
Loading

0 comments on commit 5c176ac

Please sign in to comment.