Commit Graph

12 Commits (2164a437c0498be46cf2bcb1fb6d7a276976753e)

Author SHA1 Message Date
Mauren Berti a3b7cfd886
Add in-place substitution option for linkchecker.py (#41983)
* Add in-place replacement option for linkchecker.py

Add a new flag '-w' to enable an experimental in-place replacement for Markdown
links only.

* Apply suggestions from code review

Use formatted string literals instead of simple concatenation.

Co-authored-by: Matt Boersma <Matt.Boersma@microsoft.com>

* Remove other paths that should not be changed.

* Add more logic to remove paths that start with http or paths that are already linking to the localized page (i.e. start with '/<language-code>').

* Apply suggestions from code review

Simplify expressions.

Co-authored-by: Matt Boersma <Matt.Boersma@microsoft.com>

* Avoid updating pages in English.

* Fix syntax error in set comprehension

* Expand on documentation for new -w flag

* Update documentation for linkchecker.py in README

* Add a blurb with information about the new -w
  switch that describes what it does and what is
  the purpose of adding this behaviour change.
* Update the previously existing description to
  match the currently available script flags.

---------

Co-authored-by: Matt Boersma <Matt.Boersma@microsoft.com>
2023-07-14 10:07:49 -07:00
Miguel Garcia 754bee9fab linkchecker: detect absolute links with missing leading slash
When an absolute link is missing the leading slash (it starts with
"docs/foo" instead of "/docs/foo/"), print a more specific error instead
of the generic catch-all warning.

Without the leading slash, these are treated as relative paths and so
lead to non-existing pages.

Also, while we're at it, fix the instance it detects.
2023-05-27 23:19:29 +02:00
Kenichi Omichi 88f993b12e Add verify-spelling.sh for ja content
We have the translation guideline as [1], and that contains what are
valid Japanese words for the corresponding English words.
This adds a script to verify those words based on the guideline.

[1]: https://kubernetes.io/ja/docs/contribute/localization/
2022-12-14 08:57:14 +09:00
howieyuen f0ccbff316 [zh]Update other pages for links with '/zh/' prefix, using new prefix '/zh-cn/' 2022-06-24 11:13:35 +08:00
s-kawamura-w664 7fde0426df Add script for detecting bad characters.
Co-authored-by: Shu Muto <shu.mutow@nec.com>
2021-04-08 09:36:11 +00:00
BITLIU 2eee57c425
Complete scripts descriptions
add lsync.sh hash-files.sh linkchecker.py  description

remove  replace-capture.sh description
2021-03-26 09:30:33 +08:00
BITLIU 357a1225f6
Update scripts/README.md
Co-authored-by: Tim Bannister <tim@scalefactory.com>
2021-03-26 09:27:01 +08:00
BITLIU 8cf40d5dea
Complete Scripts Description
Add 4 new Scripts to README
2021-03-25 20:50:54 +08:00
Jacky Wu 92e30010bd
cleanup: remove hugo-version-check.sh. (#18817) 2020-02-11 11:28:07 -08:00
Rémy Léone 9b5a1768bd Update README.md (#16552) 2019-09-28 12:37:38 -07:00
June Yi b76689388b Add a helper script for localization (#15789)
* Add a helper script for localization

The script generates a report of outdated contents in
`content/<l10n-lang>` directory by comparing two l10n
team milestone branches.

* Add description for scripts/diff_l10n_branches.py
2019-09-09 22:22:53 -07:00
Rémy Léone 8b78d7f685 Add readme for scripts (#14913) 2019-07-08 15:24:00 -07:00