Skip to content

Commit

Permalink
Update sitemaps.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
glenn-jocher authored Nov 20, 2023
1 parent 3b5e31f commit 71bf53d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/sitemaps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ name: Submit Sitemaps

on:
workflow_dispatch:
pull_request:
branches: [main]
workflow_run:
workflows: ["pages-build-deployment"]
types:
Expand Down Expand Up @@ -53,11 +55,11 @@ jobs:
print(f'ERROR ❌: {sitemap_url} failed to submit {e}')
credentials_json = os.environ['CREDENTIALS_JSON']
# Submit sitemap for the main site and main docs
submit_sitemap('https://docs.ultralytics.com', 'https://docs.ultralytics.com/sitemap.xml', credentials_json)
# submit_sitemap('https://docs.ultralytics.com', 'https://docs.ultralytics.com/sitemap.xml', credentials_json)
# Submit sitemaps for each language
languages = ['zh', 'ko', 'ja', 'ru', 'de', 'fr', 'es', 'pt', 'hi', 'ar']
for lang in languages:
submit_sitemap(f'https://docs.ultralytics.com/', f'https://docs.ultralytics.com/{lang}/sitemap.xml', credentials_json)
pass # submit_sitemap(f'https://docs.ultralytics.com/', f'https://docs.ultralytics.com/{lang}/sitemap.xml', credentials_json)
- name: Submit URLs to IndexNow
env:
Expand Down Expand Up @@ -121,4 +123,4 @@ jobs:
print(f'Filtered {len(urls_to_submit)} updated pages to submit)')
# Submit filtered URLs
submit_urls_to_indexnow(host, urls_to_submit)
# submit_urls_to_indexnow(host, urls_to_submit)

0 comments on commit 71bf53d

Please sign in to comment.