Creating and Editing the Community Page

This page describes how to create and edit a Community page at WikiPathways.

Clone Necessary Repositories

To create a new Community page or to edit an existing page, you will need to make edits to two repositories. If you have write access to these, you can simply commit your changes, otherwise create a pull request. You can edit the files (markdown and text) in any text editor, but a code editor is recommended, for example Visual Studio Code.

  1. Clone wikipathways-database.
  2. Clone wikipathways.github.io.
  3. For wikipathways.github.io, refer to the README for instructions on how to build the site locally for testing purposes.

Define or Update the Pathway Set

The pathway set defined for each Community is simply a flat file list of all WikiPathways Identifiers (WPIDs) relevant for that Community. The list of pathway IDs for each Community is stored in the wikipathways-database repository, in the communities directory.

Add a pathway list for a new Community page:

  1. Create a simple .txt file with the relevant WPIDs listed as one column, no header.
  2. Give the the .txt file a name that can also be used as the community-tag. These two must be identical. In the below example of the AOP Community, the name of the pathway list file and the community-tag is "AOP".
  3. Push your changes to GitHub (if you have permissions) or create a pull request.

Update the list of pathways for an existing Community page:

  1. Option 1: Edit the appropriate file in your local clone of the repo, followed by a push to GitHub (if you have write permissions) or a pull request.
  2. Option 2: Click the Edit community pathways button (pencil icon) on the Community page, and make the edit directly in the GitHub web interface.

Create or Edit a Community Page

All Commuity pages are designed using the same template layout, and the content of each Community is defined in a markdown file in the communities directory. In order to be processed correctly by Jekyll, the markdown file must have a YAML front matter block at the beginning of the file, defining a set of custom variables. The front matter must be contained within a set of triple-dashed lines (---). After the front matter code, the file can contain additional html for custom content. The variables defined for WikiPathways Communities are:

  • display-name: The name of the Community displayed on the Communities page
  • title
  • description: Text describing the Community
  • short-description: One or two sentences describing the Community, displayed on the Communities page
  • logo: a link to a png image (optional)
  • logo-link: URL for an external resource (optional)
  • support: Text describing any funding support for the Community (optional)
  • contribute: Text describing how to contribute to the community (optional)
  • community-tag: The relevant community tag. This should match the filename of the text file with the list of Community pathways The pathway display on the Community page is automatically generated based on this tag
  • redirect_from: Partial URL on the old WikiPathways site to redirect from

As an example, the below image shows the markdown for the Adverse Outcome Pathways Community.

Markdown Example

Create a new Community page:

  1. In your local clone of the wikipathways.github.io repo, create a new .md file in the communities directory. Pro-tip: copy an existing file and rename it.
  2. Edit the contents of the variables for your Community.
  3. Save the .md file and either push the change to GitHub (if you have write permissions) or create a pull request.

Edit an existing Community page:

  1. Option 1: Edit the appropriate .md file in your local clone of the repo, followed by a push to GitHub (if you have write permissions) or a pull request.
  2. Option 2: Edit the .md file directly in the GitHub web interface.