Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[backport 3.12.x] Add documentation to GitHub workflows #7414

Merged
merged 4 commits into from
Oct 10, 2023
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
41 changes: 41 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Documentation

on:
push:
branches:
- 3.12.x
paths:
- "docs/manual/**"
pull_request:
branches:
- 3.12.x
paths:
- "docs/manual/**"
workflow_dispatch:

jobs:
deploy-docs:
runs-on: ubuntu-latest
steps:
- name: Checkout GeoNetwork
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Python
uses: actions/setup-python@v4
with:
python-version: 3.x
- name: mkdocs install
run: pip install --upgrade pip && pip install -r docs/manual/requirements.txt
- name: git configuration
run: git config user.name 'github-actions[bot]' && git config user.email 'github-actions[bot]@users.noreply.github.com'
- name: build docs without publishing them
if: ${{ github.event_name == 'pull_request' }}
working-directory: docs/manual
run: |
mike deploy --title "3.12 Maintenance" --no-redirect --update-aliases 3.12 maintenance
- name: deploy maintenance docs to gh-pages branch
if: ${{ github.event_name != 'pull_request' }}
working-directory: docs/manual
run: |
mike deploy --push --title "3.12 Maintenance" --no-redirect --update-aliases 3.12 maintenance
16 changes: 12 additions & 4 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Linux GitHub CI
on: [pull_request,push,workflow_dispatch]

env:
MAVEN_OPTS: -Dmaven.wagon.httpconnectionManager.ttlSeconds=25 -Dmaven.wagon.http.retryHandler.count=3 -Xmx512m -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss,SSS
MAVEN_OPTS: -Dmaven.wagon.httpconnectionManager.ttlSeconds=25 -Dmaven.wagon.http.retryHandler.count=3 -Xmx512m -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss,SSS -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
TAKARI_SMART_BUILDER_VERSION: 0.6.1

jobs:
Expand All @@ -22,17 +22,25 @@ jobs:
submodules: 'recursive'
show-progress: 'false'
- name: Set up JDK
uses: actions/setup-java@v3.9.0
uses: actions/setup-java@v3.12.0
with:
distribution: 'temurin'
java-version: ${{ matrix.jdk }}
cache: 'maven'
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: 3.x
- name: mkdocs install
working-directory: docs/manual
run: pip install --upgrade pip && pip install -r requirements.txt
- name: Set up Maven
uses: stCarolas/setup-maven@v4
with:
maven-version: 3.6.3
- name: Build with Maven
run: mvn -B -V install -DskipTests=true -Dmaven.javadoc.skip=true
run: |
mvn -B -ntp -V install -DskipTests=true -Dmaven.javadoc.skip=true -Pwith-doc
- name: Remove SNAPSHOT jars from repository
run: |
find ~/.m2/repository -name "*SNAPSHOT*" -type d | xargs rm -rf {}
Expand All @@ -50,7 +58,7 @@ jobs:
submodules: 'recursive'
show-progress: 'false'
- name: Set up JDK
uses: actions/setup-java@v3.9.0
uses: actions/setup-java@v3.12.0
with:
distribution: 'temurin'
java-version: 8
Expand Down
13 changes: 10 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
# Extensions
*.factorypath
*.iml
*.iml
*.bak
*.launch
*.old
*.bak
.DS_Store
.project
git*.properties
Expand All @@ -15,8 +14,9 @@ git*.properties
*/.*
*/target/
.*/
!.github/
!.github

#GeoNetwork*
/geonetwork*
camel-harvesters/wfsfeature-harvester/logs
changes-*
Expand All @@ -29,6 +29,7 @@ docs/schema-loc-*.rst
eclipse/
es/elasticsearch-*
es/es-dashboards/kibana-*
es/es-dashboards/data/nodes/
harvesters/harvester_*.log
idea/
jcs_caching/
Expand All @@ -41,6 +42,9 @@ schemas/*/doc/*/*.rst
schematrons/.build
target/
transifex/transifex-format/

# web-app, clear using: mvn -f web/pom.xml clean:clean@reset

web-itest/jcs_caching
web-ui-docs/node
web-ui-docs/node_modules
Expand All @@ -57,6 +61,8 @@ web/jcs_caching/
web/logs/
web/src/main/webapp/META-INF/MANIFEST.MF
web/src/main/webapp/WEB-INF/data/0*
web/src/main/webapp/WEB-INF/data/config/encryptor.properties
web/src/main/webapp/WEB-INF/data/config/index/records.json
web/src/main/webapp/WEB-INF/data/config/schema_plugins/*/schematron/schematron*.xsl
web/src/main/webapp/WEB-INF/data/config/schema_plugins/csw-record
web/src/main/webapp/WEB-INF/data/config/schema_plugins/dublin-core
Expand All @@ -83,6 +89,7 @@ web/src/main/webapp/WEB-INF/data_*
web/src/main/webapp/WEB-INF/lucene/
web/src/main/webapp/WEB-INF/metadata_subversion/
web/src/main/webapp/WEB-INF/server.prop
web/src/main/webapp/WEB-INF/prebuilt
web/src/main/webapp/data/
web/src/main/webapp/doc/en
web/src/main/webapp/doc/fr
Expand Down
2 changes: 1 addition & 1 deletion docs/manual/docs/index.fr.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ hide:
- navigation
---

# GeoNetwork {#toc}
# GeoNetwork 3.12 {#toc}

Bienvenue à GeoNetwork. Cette documentation est organisée en guides spécifiques destinés à différents publics.

Expand Down
2 changes: 1 addition & 1 deletion docs/manual/docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ hide:
- navigation
---

# GeoNetwork {#toc}
# GeoNetwork 3.12 {#toc}

Welcome to GeoNetwork. This documentation is organized into specific guides targeting different audience.

Expand Down
2 changes: 1 addition & 1 deletion docs/manual/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ markdown_extensions:

# Page tree
nav:
- index.md
- 'GeoNetwork': index.md
- 'Overview':
- overview/index.md
- overview/about.md
Expand Down
4 changes: 2 additions & 2 deletions docs/manual/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>gn-docs</artifactId>
<artifactId>docs</artifactId>
<groupId>org.geonetwork-opensource</groupId>
<version>4.4.0-SNAPSHOT</version>
<version>3.12-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>gn-guide</artifactId>
Expand Down
Loading