-
Notifications
You must be signed in to change notification settings - Fork 177
How to Add and Edit Categories and Top Categories
Adding and Editing Categories and Top Categories should be done via merging a forked repository. If you have not set one up, follow the instructions under "Fork the repository (One-time setup)" in Editing with Forks
Netlify CMS does not currently have functionality to add and edit categories.
It is useful to group rules into categories, for better perusal!
Follow these steps:
- Go to the category index public page (E.g. https://ssw.com.au/rules/rules-to-better-communication)
- Click on 'edit in GitHub'
- Click on the little pencil to edit the Markdown file
- Add a new rule URI to the "index" list, in the desired position
Follow the same steps 1-3 above, then update the list order by moving items around as needed.
---
type: category
title: Rules to Better Communication
guid: 471816bf-f0df-4835-bf4d-66a90f6f1adc
uri: rules-to-better-communication
experts: https://www.ssw.com.au/people/?skill=Scrum
consulting: https://www.ssw.com.au/consulting/scrum
index:
- some-rule
- another-rule
- some-other-rule
- a-fourth-rule
---
This is a summary for the category
If you think SSW.Rules need a whole new category for one or more rule, follow these steps to create it:
- Go to your forked repository.
- Decide on which Top Category your Category should belong to.
- Open the
categories/{top-category name}
(e.g. categories/Communication) folder. - Click
Add file | Create new file
- Name your file
{category name}.md
(e.g. 'rules-to-better-communication.md'). - In the your
{category name}.md
file, you need to add the following fields in the frontmatter-
type:
value must be set to 'category' -
title:
the title of the category, this will be display on the home page and the category page -
index:
A markdown list of URIs of the rules composing the category -
uri:
same as the name of the file without the .md extension -
guid:
a unique guid used to identify the category in the Cosmos DB- You can use guidgen.com/ to get a guid
-
experts:
An optional redirect to the SSW People page with a certain tag, e.g. https://www.ssw.com.au/people/?skill={{skill}} -
consulting:
An optional redirect to a consulting page, e.g. https://www.ssw.com.au/consulting/{{consulting-page}}
-
- You can also add a summary for the category after the frontmatter.
-
Important: In the index.md file of the top category, add your category URI to the list of categories under
index:
Frontmatter and summary example:
---
type: category
title: Rules to Better Communication
guid: 471816bf-f0df-4835-bf4d-66a90f6f1adc
uri: rules-to-better-communication
experts: https://www.ssw.com.au/people/?skill=Scrum
consulting: https://www.ssw.com.au/consulting/scrum
index:
- the-best-chat-tools-for-your-employees
- options-for-remote-meetings
- always-call-first-before-emailing
---
This is a summary for the category
Figure: Frontmatter example for a category
Tip: Don't add a new line after the front matter as this has caused issues in the past.
If you need to edit a category, follow these steps:
- Go to your forked repository.
- Find the category you want to edit under
categories | {your category's top-category} | {your category}.md
- Click on the pencil button.
- Make the changes you want.
- Merge your changes, see Merging Your Fork
For the SSW.Rules markdown syntax, read the sample page
WARNING: Do not leave categories empty.
A top category is a group of categories that are related!
If you think rules could have a new top-category, follow these steps:
- Go to your forked repository
- Open the
categories
folder - Click
Add file | Create new file
- Name your file
{top-category name}/index.md
(e.g, 'software-development/index.md') - Edit the
index.md file
, and add the following fields in the frontmatter-
type:
value must be set totop-category
-
title:
the title of the top-category, this will be display on the home page (e.g Software Development) -
uri:
the URI for the new category (e.g. software-development) -
index:
A markdown list of categories URI composing the top-category
-
---
type: top-category
title: Software Development
uri: software-development
index:
- rules-to-better-net-projects
- rules-to-better-architecture-and-code-review
- rules-to-better-azure
- rules-to-better-devops
- rules-to-better-mvc
- rules-to-better-bots
- rules-to-better-clean-architecture
- rules-to-better-bug-management-and-feedback
- rules-to-better-user-acceptance-tests-uat-for-bug-management
- rules-to-better-crm-for-developers
- rules-to-better-power-platform
- rules-to-better-sharepoint-for-developers
- rules-to-better-code-commenting
---
Figure: Frontmatter example for a top-category
To edit a top-category, follow these steps:
- Go to your forked repository
- Open the folder
categories | {top-category name}
- Open the
index.md
file - Click on the pencil to edit
- Make the changes you want
- Merge your changes, see Merging Your Fork