-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create a script to update internal links of translated files #817
Comments
@think-in-universe you might like this bounty 😄 |
Issue Status: 1. Open 2. Started 3. Submitted 4. Done This issue now has a funding of 75.0 DAI (75.0 USD @ $1.0/DAI) attached to it as part of the ethereum fund.
|
Issue Status: 1. Open 2. Started 3. Submitted 4. Done Work has been started. These users each claimed they can complete the work by 264 years, 8 months from now. 1) sebastiantf has started work. will develop the script. Have experience in Javascript Will build the script according to the bounty description Learn more on the Gitcoin Issue Details page. |
Issue Status: 1. Open 2. Started 3. Submitted 4. Done Work for 75.0 DAI (75.0 USD @ $1.0/DAI) has been submitted by: @samajammin please take a look at the submitted work:
|
@samajammin thanks for invitation 😄 it seems already done. thank you guys for the quick work~ |
Issue Status: 1. Open 2. Started 3. Submitted 4. Done The funding of 75.0 DAI (75.0 USD @ $1.0/DAI) attached to this issue has been approved & issued to @antodp.
|
Prize Bounty
75 DAI
Challenge Description
Currently when adding a new language translation or updating an existing translation (e.g. #816), all internal links within the translated markdown files must be manually updated to point to the appropriate page (i.e. the translated page vs. the corresponding English page). For instance, a link to the /learn page within the /docs/sv/what-is-ethereum/index.md file must be updated from
/learn
to/sv/learn
(so it points to the translated page, ethereum.org/sv/learn, not the English version at ethereum.org/learn). See this commit as an example.Create a node script to automate these updates.
Submission Requirements
The node script should take a language directory as an argument, e.g.:
This script should traverse all markdown files within the directory for internal links, e.g.
It should IGNORE all external links, e.g.
For each internal link:
The script should check that the passed argument (the language directory) is in fact a valid language directory (e.g. by checking the directory names within /docs/translations/, or keys of the
locales
object in config.js).Describe alternatives you've considered
Additional context
It may be useful to check out the existing script at generateHeadingID.js as an example to work off.
Judging Criteria
The prize will be awarded to the first valid submission.
The text was updated successfully, but these errors were encountered: