mirror of
https://github.com/Alex38Lyon/Synthese-PSM_LARRA.git
synced 2026-09-30 07:21:55 +00:00
Refactor Python script execution in workflow
This commit is contained in:
@@ -381,8 +381,7 @@ jobs:
|
|||||||
echo "pyThtoQgis"
|
echo "pyThtoQgis"
|
||||||
echo "========================================"
|
echo "========================================"
|
||||||
cd Scripts/pyThtoQgis
|
cd Scripts/pyThtoQgis
|
||||||
python pyThtoQgis.py \
|
python pyThtoQgis.py --folder "../../Outputs/SHP/"
|
||||||
--folder "../../Outputs/SHP/"
|
|
||||||
|
|
||||||
# ============================================================
|
# ============================================================
|
||||||
# 14. Vérification base SQL
|
# 14. Vérification base SQL
|
||||||
@@ -406,22 +405,7 @@ jobs:
|
|||||||
|
|
||||||
# ============================================================
|
# ============================================================
|
||||||
# 15. Exécution pyThStat
|
# 15. Exécution pyThStat
|
||||||
# ============================================================
|
# ============================================================
|
||||||
# ============================================================
|
|
||||||
# Recherche pyThStat.py
|
|
||||||
# ============================================================
|
|
||||||
- name: Find pyThStat.py
|
|
||||||
if: steps.changed.outputs.shp == 'true'
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
echo "========================================"
|
|
||||||
echo "RECHERCHE pyThStat.py"
|
|
||||||
echo "========================================"
|
|
||||||
find . \
|
|
||||||
-type f \
|
|
||||||
-name "pyThStat.py" \
|
|
||||||
-print
|
|
||||||
|
|
||||||
- name: Run pyThStat
|
- name: Run pyThStat
|
||||||
if: steps.changed.outputs.shp == 'true'
|
if: steps.changed.outputs.shp == 'true'
|
||||||
shell: bash -el {0}
|
shell: bash -el {0}
|
||||||
@@ -432,42 +416,30 @@ jobs:
|
|||||||
echo "========================================"
|
echo "========================================"
|
||||||
cd ..
|
cd ..
|
||||||
cd Scripts/pyThStat
|
cd Scripts/pyThStat
|
||||||
python pyThStat.py \
|
python pyThStat.py --file "../../Outputs/DB_Synthese-PSM_LARRA.sql"
|
||||||
--file "../../Outputs/DB_Synthese-PSM_LARRA.sql"
|
|
||||||
|
|
||||||
# ============================================================
|
# ============================================================
|
||||||
# 16. Fichiers produits
|
# 16. Fichiers produits
|
||||||
# ============================================================
|
# ============================================================
|
||||||
|
|
||||||
- name: Show generated files
|
- name: Show generated files
|
||||||
if: steps.changed.outputs.shp == 'true'
|
if: steps.changed.outputs.shp == 'true'
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
|
|
||||||
echo "========================================"
|
echo "========================================"
|
||||||
echo "GENERATED FILES"
|
echo "GENERATED FILES"
|
||||||
echo "========================================"
|
echo "========================================"
|
||||||
|
|
||||||
|
|
||||||
git status --short
|
git status --short
|
||||||
|
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
git diff --stat
|
git diff --stat
|
||||||
|
|
||||||
|
|
||||||
# ============================================================
|
# ============================================================
|
||||||
# 17. Commit
|
# 17. Commit
|
||||||
# ============================================================
|
# ============================================================
|
||||||
|
|
||||||
- name: Commit generated files
|
- name: Commit generated files
|
||||||
if: steps.changed.outputs.shp == 'true'
|
if: steps.changed.outputs.shp == 'true'
|
||||||
uses: stefanzweifel/git-auto-commit-action@v7
|
uses: stefanzweifel/git-auto-commit-action@v7
|
||||||
with:
|
with:
|
||||||
|
|
||||||
commit_message: "Auto-generate outputs from SHP"
|
commit_message: "Auto-generate outputs from SHP"
|
||||||
|
|
||||||
commit_user_name: "github-actions[bot]"
|
commit_user_name: "github-actions[bot]"
|
||||||
|
|
||||||
commit_user_email: "41898282+github-actions[bot]@users.noreply.github.com"
|
commit_user_email: "41898282+github-actions[bot]@users.noreply.github.com"
|
||||||
|
|||||||
Reference in New Issue
Block a user