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
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,13 @@
# ------------------------------------------------------------------------------



DIR=$(git rev-parse --show-toplevel)

pushd "${DIR}" > /dev/null || exit 1

mkdir -p build
pushd build > /dev/null || exit 1
cmake -DWITH_DOC=ON -DCMAKE_BUILD_TYPE=Release -DLOCALE=ON ..
cmake -DBUILD_LOCALE=ON ..

make locale
popd > /dev/null || exit 1
Expand All @@ -39,7 +38,12 @@ perl -ne '/\/en\// && print' build/doc/locale_changes_po.txt | \
perl -pe 's/(.*)en\/LC_MESSAGES(.*)/$1pot$2t/' >> build/doc/locale_changes_po_pot.txt # .pot files

# Remove obsolete entries #~ from .po files
bash tools/transifex/remove_obsolete_entries.sh
find locale -type f -name '*.po' -exec sh -c '
if grep -q "#~" "$1"; then
perl -pi -0777 -e "s/#~.*//s" "$1"
git add "$1"
fi
' sh {} \;

while read -r f; do git add "$f"; done < build/doc/locale_changes_po_pot.txt

Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/check-queries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,6 @@ jobs:
run: |
cd build
make doxy
[ ! -s DOXYLOG ] || echo "There are Doxygen warnings" && exit 1
more DOXYLOG
[ ! -s DOXYLOG ] || echo "There are Doxygen warnings"
[ ! -s DOXYLOG ] || exit 1
11 changes: 4 additions & 7 deletions .github/workflows/doc-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,23 +103,20 @@ jobs:
sudo apt-get update
sudo apt-get install -y \
libboost-graph-dev \
python3-sphinx \
python3-sphinx-bootstrap-theme \
postgresql-${PGVER} \
postgresql-server-dev-${PGVER} \
graphviz
python -m pip install --upgrade pip
pip install -r requirements.txt
pip list


- name: Configure
if: env.PROCESS == 'true'
run: |
export PATH=/usr/lib/postgresql/${PGVER}/bin:$PATH
mkdir build
cd build
cmake -DLINKCHECK=ON -DWITH_DOC=ON \
-DES=ON -DZH_HANS=ON \
-DPOSTGRESQL_VERSION=${PGVER} -DCMAKE_BUILD_TYPE=Release ..
cmake -DBUILD_LINKCHECK=ON \
-DPOSTGRESQL_VERSION=${PGVER} ..

- name: Check Documentation
if: env.PROCESS == 'true'
Expand Down
25 changes: 9 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,41 +70,34 @@ jobs:
sudo apt-get update
sudo apt-get install -y \
libboost-graph-dev \
python3-sphinx \
python3-sphinx-bootstrap-theme \
postgresql-${PGVER} \
postgresql-${PGVER}-postgis-${PGIS} \
postgresql-${PGVER}-postgis-${PGIS}-scripts \
postgresql-server-dev-${PGVER} \
graphviz \
doxygen
python -m pip install --upgrade pip
pip install Sphinx
pip install sphinx-bootstrap-theme
pip install sphinx-collapse
pip list

- name: Configure
- name: Configure and build
run: |
export PATH=/usr/lib/postgresql/${PGVER}/bin:$PATH
mkdir build
cd build
cmake -DPOSTGRESQL_VERSION=${PGVER} -DDOC_USE_BOOTSTRAP=ON -DWITH_DOC=ON -DBUILD_DOXY=ON -DCMAKE_BUILD_TYPE=Release \
-DES=ON -DZH_HANS=ON ..

- name: Build
run: |
cd build
cmake -DPOSTGRESQL_VERSION=${PGVER} \
-DDOC_USE_BOOTSTRAP=ON \
-DCMAKE_BUILD_TYPE=Release ..
make doc
make -j 4
sudo make install
make doxy
sudo make -j 4 install

- name: Update Users Documentation
run: |
git checkout origin/gh-pages
git checkout -b gh-pages
PGROUTING_MAJOR_MINOR="${PGROUTING_VERSION%.*}"
rm -rf ${PGROUTING_MAJOR_MINOR}
cp -r build/doc/html ${PGROUTING_MAJOR_MINOR}
cp -r build/doc/_build/html ${PGROUTING_MAJOR_MINOR}
git add ${PGROUTING_MAJOR_MINOR}
git diff-index --quiet HEAD || git commit -m "Update users documentation for ${PGROUTING_VERSION}: commit ${{ env.GIT_HASH }}"
git fetch origin
Expand Down Expand Up @@ -136,7 +129,7 @@ jobs:
run: |
cd build/doc

cp -r html doc-v${PGROUTING_VERSION}
cp -r _build/html doc-v${PGROUTING_VERSION}
tar -zcvf doc-v${PGROUTING_VERSION}.tar.gz doc-v${PGROUTING_VERSION}

cd ../..
Expand Down
32 changes: 11 additions & 21 deletions .github/workflows/update-locale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,22 +34,18 @@ jobs:
with:
fetch-depth: 0

- name: Get postgres version
run: |
sudo service postgresql start
PGVER=$(psql --version | grep -Po '(?<=psql \(PostgreSQL\) )[^;]+(?=\.\d+ \()')
PROJECT_VERSION=$(grep -Po '(?<=project\(PGROUTING VERSION )[^;]+' CMakeLists.txt)
echo "PGVER=${PGVER}" >> $GITHUB_ENV
echo "PGPORT=5432" >> $GITHUB_ENV
echo "PGIS=3" >> $GITHUB_ENV
echo "PROJECT_VERSION=${PROJECT_VERSION}" >> $GITHUB_ENV

- name: Extract branch name and commit hash
run: |
branch=${GITHUB_REF#refs/heads/}
git_hash=$(git rev-parse --short "$GITHUB_SHA")
echo "GIT_HASH=$git_hash" >> $GITHUB_ENV

- name: Get postgres version
run: |
sudo service postgresql start
pgver=$(psql --version | grep -Po '(?<=psql \(PostgreSQL\) )[^;]+(?=\.\d+ \()')
echo "PGVER=${pgver}" >> $GITHUB_ENV

- name: Add PostgreSQL APT repository
run: |
sudo apt-get install curl ca-certificates gnupg
Expand All @@ -67,18 +63,12 @@ jobs:
sudo apt-get update
sudo apt-get install -y \
libboost-graph-dev \
python3-sphinx \
python3-sphinx-bootstrap-theme \
sphinx-intl \
postgresql-${PGVER} \
postgresql-${PGVER}-postgis-${PGIS} \
postgresql-${PGVER}-postgis-${PGIS}-scripts \
postgresql-server-dev-${PGVER} \
graphviz \
doxygen
python -m pip install --upgrade pip
pip install Sphinx
pip install sphinx-bootstrap-theme
pip install sphinx-intl[transifex]
pip install sphinx-collapse
pip list
graphviz

- name: Initialize mandatory git config
run: |
Expand All @@ -87,7 +77,7 @@ jobs:

- name: Update locale
run: |
bash tools/transifex/update_locale.sh
bash .github/scripts/update_locale.sh

# Add the files, commit and push
git diff --staged --quiet || git commit -m "Update locale: commit ${{ env.GIT_HASH }}"
Expand Down
17 changes: 7 additions & 10 deletions .github/workflows/website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,26 +66,23 @@ jobs:
sudo apt-get update
sudo apt-get install -y \
libboost-graph-dev \
python3-sphinx \
python3-sphinx-bootstrap-theme \
postgresql-${PGVER} \
postgresql-${PGVER}-postgis-${PGIS} \
postgresql-${PGVER}-postgis-${PGIS}-scripts \
postgresql-server-dev-${PGVER} \
graphviz \
doxygen
python -m pip install --upgrade pip
pip install Sphinx
pip install sphinx-bootstrap-theme
pip install sphinx-intl[transifex]
pip install sphinx-collapse
pip list

- name: Configure and build documentation
run: |
export PATH=/usr/lib/postgresql/${PGVER}/bin:$PATH
mkdir build
cd build
cmake -DPOSTGRESQL_VERSION=${PGVER} -DDOC_USE_BOOTSTRAP=ON -DWITH_DOC=ON -DBUILD_DOXY=ON \
-DCMAKE_BUILD_TYPE=Release -DES=ON -DZH_HANS=ON ..
cmake -DPOSTGRESQL_VERSION=${PGVER} \
-DDOC_USE_BOOTSTRAP=ON \
-DCMAKE_BUILD_TYPE=Release ..
make doc

- name: Initialize mandatory git config
Expand All @@ -102,7 +99,7 @@ jobs:
git checkout -b gh-pages
DIRECTORY="${PROJECT_VERSION%.*}"
rm -rf ${DIRECTORY}
cp -r build/doc/html ${DIRECTORY}
cp -r build/doc/_build/html ${DIRECTORY}
git add ${DIRECTORY}
git diff-index --quiet HEAD || git commit -m "Update users documentation for ${PROJECT_VERSION} for develop branch: commit ${{ env.GIT_HASH }}"
git fetch origin
Expand All @@ -120,7 +117,7 @@ jobs:
git checkout -b gh-pages
DIRECTORY="main"
rm -rf ${DIRECTORY}
cp -r build/doc/html ${DIRECTORY}
cp -r build/doc/_build/html ${DIRECTORY}
git add ${DIRECTORY}
git diff-index --quiet HEAD || git commit -m "Update users documentation for ${PROJECT_VERSION} for main branch: commit ${{ env.GIT_HASH }}"
git fetch origin
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ include(pgr/Configure)
#---------------------------------------------
set(DOXYGEN_MINIMUM_VERSION "1.7")
set(SPHINX_MINIMUM_VERSION "4.0")
set(POSTGRESQL_MINIMUM_VERSION "13.0.0")
set(POSTGRESQL_MINIMUM_VERSION "13")
set(BOOST_MINIMUM_VERSION "1.56.0")
set(POSTGIS_MINIMUM_VERSION "3.0.0")

Expand Down
Loading