main
parent
1f03dbdf32
commit
73130e9b9b
@ -1,39 +0,0 @@
|
|||||||
name: Generate xml sitemap
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches: [ main ]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
sitemap_job:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
name: Generate a sitemap
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout the repo
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- name: Generate the sitemap
|
|
||||||
id: sitemap
|
|
||||||
uses: cicirello/generate-sitemap@v1
|
|
||||||
with:
|
|
||||||
base-url-path: https://tools.pj568.eu.org/
|
|
||||||
|
|
||||||
- name: Output stats
|
|
||||||
run: |
|
|
||||||
echo "sitemap-path = ${{ steps.sitemap.outputs.sitemap-path }}"
|
|
||||||
echo "url-count = ${{ steps.sitemap.outputs.url-count }}"
|
|
||||||
echo "excluded-count = ${{ steps.sitemap.outputs.excluded-count }}"
|
|
||||||
|
|
||||||
- name: Push sitemap to repository
|
|
||||||
run: |
|
|
||||||
git config --global user.name "PJ569-bot"
|
|
||||||
git config --global user.email "LiuTian-PJ568@PJ568.eu.org"
|
|
||||||
git add sitemap.xml
|
|
||||||
git commit -m "add sitemap.xml"
|
|
||||||
git push
|
|
||||||
|
|
||||||
- name: Ping Google
|
|
||||||
run: curl https://www.google.com/ping?sitemap=https://Tools.PJ568.eu.org/sitemap.xml
|
|
Loading…
Reference in new issue