GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — InnerSourceLearningPath/scripts at main · InnerSourceCommons/InnerSourceLearningPath

Expand file tree

/

scripts

/
Copy path

Directory actions

More options

More options

Directory actions

More options

More options

Latest commit

 

History

History
History
/

scripts

/
Copy path

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
.node-version
.node-version
 
 
README.md
README.md
 
 
generate_learning_path_markdown.js
generate_learning_path_markdown.js
 
 
get_article_files.js
get_article_files.js
 
 
get_contributors.js
get_contributors.js
 
 
mkdir_sync.js
mkdir_sync.js
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
section_data.json
section_data.json
 
 
substitute_article_urls.js
substitute_article_urls.js
 
 
update_links_in_translations.js
update_links_in_translations.js
 
 
write_markdown_file.js
write_markdown_file.js
 
 

README.md

Outline

All of these scripts require you to have Node available in your environment. Get it from NodeJS.org.

substitute_article_urls.js

A node script to replace all Learning Path article links with urls for a particular platform, using urls.yaml.

Usage:

npm ci
node substitute_article_urls.js $TARGET

For example, to point all links to innersourcecommons.org:

node substitute_article_urls.js isc

update_links_in_translations.js

A node script to ensure article links point at the relevant translation if it exists, or default (English) if not.

Usage:

npm ci
node update_links_in_translations.js

generate_learning_path_markdown.js

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>

Usage:

npm ci
node generate_learning_path_markdown.js

The -e param generates only English-language articles, which can speed things up quite a bit if you just need one language to test out some changes.

How to update innersourcecommons.org with new articles

Anytime there are any changes, you need to run the script that generates the updated pages on the innersourcecommons.org site.

  1. Clone the InnerSourceCommons/InnerSourceLearningPath and InnerSourceCommons/innersourcecommons.org repos.
  2. Is this the first time that articles have been written for this language? If so:
    • Make sure this language appears in the website config and there is an index page.
  3. Is there a whole new Learning Path section? If so:
    • Create a new thumbnail and put it with the other thumbnails.
    • Create an index.md in the section folder.
    • Update the "sections" config with the new section and open a pull request for the change.
  4. Run generate_learning_path_markdown.js as described above.
  5. cp -r newsite/* <path-to-innersourcecommons.org-repo>/content/en/learn/learning-path/.
  6. Open a pull request with the modified files in the InnerSourceCommons/innersourcecommons.org repo.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.