All of these scripts require you to have Node available in your environment. Get it from NodeJS.org.
A node script to replace all Learning Path article links with urls for a particular platform, using urls.yaml.
npm ci
node substitute_article_urls.js $TARGET
For example, to point all links to innersourcecommons.org:
node substitute_article_urls.js isc
A node script to generate markdown files required for hosting Learning Path on innersourcecommons.org.
This script requires a GitHub access token, as it uses the GitHub API to get Learning Path contributors. Your token does not require any scopes, as the Learning Path is Open Source. To provide this, create a .env file in this directory in the following format:
TOKEN=<your_github_token>
npm ci
node generate_learning_path_markdown.js
Anytime there are new articles written, you need to run the script that generates the new pages on the innersourcecommons.org site.
- Clone the InnerSourceCommons/InnerSourceLearningPath and InnerSourceCommons/innersourcecommons.org repos.
- Is this the first time that articles have been written for this section in this language? If so, then do both of the following:
- update the "sections" config with the language code of the articles for the appropriate section. Open a pull request for the change.
- update the Learning Path landing page with a link to your new language pages.
- Run generate_learning_path_markdown.js as described above.
cp -r learningpath/* <path-to-innersourcecommons.org-repo>/resources/learningpath/.- Open a pull request with the modified files in the InnerSourceCommons/innersourcecommons.org repo.
Note that these steps only needs to happen when there are new articles written. Changes to existing articles will automatically show up on the innersourcecommons.org site.