-
Notifications
You must be signed in to change notification settings - Fork 167
Docs Release and Contribution Guide #6519
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
Draft
sharadregoti
wants to merge
99
commits into
master
Choose a base branch
from
contribution-guide
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from 98 commits
Commits
Show all changes
99 commits
Select commit
Hold shift + click to select a range
1e7e6f2
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti a782ebd
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti c295712
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 007acf1
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti d047927
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 7e45409
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 36edb6e
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 532e45e
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 7db9a36
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti c9382c5
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti da21473
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti e3ed48a
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 80c79a3
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 55f8c06
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti c23b4e2
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 1e212ef
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 3377dde
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 2fcac99
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 388f1b4
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs
sharadregoti 5d006bc
Fixes
sharadregoti 896d10e
fixes
sharadregoti 05c382c
Merge master into contribution-guide
buger 21e9506
Fixes
sharadregoti ddfd616
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 7b1a7e6
Merge master into contribution-guide
buger 9c532fa
Merge master into contribution-guide
buger 69e4a14
Fixes
sharadregoti e7ba968
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 0fe7ca8
fixes
sharadregoti 8094b90
Merge master into contribution-guide
buger d062060
Merge master into contribution-guide
buger b6d53ef
Merge master into contribution-guide
buger 97447b3
Merge master into contribution-guide
buger aaf9834
Fixes
sharadregoti 6f1f6cf
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 37a1f39
Merge master into contribution-guide
buger 13c0afd
Merge master into contribution-guide
buger 46af077
Merge master into contribution-guide
buger d3cfbf0
Merge master into contribution-guide
buger 1bf811f
Merge master into contribution-guide
buger 6692113
Fixes
sharadregoti 2eb1c58
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 3836c55
Merge master into contribution-guide
buger be367eb
Merge master into contribution-guide
buger 3202d44
fixes
sharadregoti 197a914
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 984a8d8
Fixes
sharadregoti f042420
Fixes
sharadregoti 2cfb302
Merge master into contribution-guide
buger 76e3114
Merge master into contribution-guide
buger ae8dac3
Merge master into contribution-guide
buger f51fbfe
Merge master into contribution-guide
buger bf09ebf
Merge master into contribution-guide
buger c9fbe7c
Merge master into contribution-guide
buger 17e74d6
Merge master into contribution-guide
buger c703185
Merge master into contribution-guide
buger 65d3eaa
Update tyk-docs/content/developer-support/content-guide.md
letzya 83b040f
Update content-guide.md
letzya 0b45fc9
Update and rename content-guide.md to contribution-guides.md
letzya 8bb7ffd
Merge master into contribution-guide
buger 423204d
Merge master into contribution-guide
buger 80db8b9
Update tyk-docs/data/menu.yaml
letzya 40a6c6f
Merge master into contribution-guide
buger f95884b
Merge master into contribution-guide
buger d613dee
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 9bea2ea
Update tyk-docs/content/developer-support/release-guide.md
letzya bf94246
Update tyk-docs/content/developer-support/release-guide.md
letzya 427039b
Fixes
sharadregoti 1819c0c
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 3889482
Fixes
sharadregoti ed39ce2
Merge branch 'master' into contribution-guide
sharadregoti 4475576
Fixes
sharadregoti f8bc881
Merge branch 'contribution-guide' of https://github.com/TykTechnologi…
sharadregoti 75e74d6
Fixes
sharadregoti af94762
Merge branch 'master' of https://github.com/TykTechnologies/tyk-docs …
sharadregoti 9462a79
Fixes
sharadregoti 204b840
Merge master into contribution-guide
buger 8bb8c8c
Merge master into contribution-guide
buger 6165b61
Merge master into contribution-guide
buger 7092eba
Merge master into contribution-guide
buger 3da1bb3
Merge master into contribution-guide
buger 8dbe5dd
Merge master into contribution-guide
buger 01b43d8
Merge master into contribution-guide
buger eb1d1ac
Merge master into contribution-guide
buger a18731e
Merge master into contribution-guide
buger 40c1cbd
Merge master into contribution-guide
buger 1641273
Merge master into contribution-guide
buger 5ba0273
Merge master into contribution-guide
buger 55d2f6b
Merge master into contribution-guide
buger 14160d4
Merge master into contribution-guide
buger fc5eb3f
Merge master into contribution-guide
buger 1f1ebbe
Merge master into contribution-guide
buger 4586609
Merge master into contribution-guide
buger f3d9f0b
Merge master into contribution-guide
buger e60193f
Merge master into contribution-guide
buger 972389b
Merge master into contribution-guide
buger ae03548
Merge master into contribution-guide
buger b5e10ff
Merge master into contribution-guide
buger 6843e6b
Apply suggestions from code review
sharadregoti File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
259 changes: 259 additions & 0 deletions
259
tyk-docs/content/developer-support/contribution-guides.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,259 @@ | ||
| --- | ||
| title: "Contributing Guides" | ||
| description: "Guide to releasing Tyk documentation" | ||
| tags: ["Guides", "Contribution to Tyk", "Open source contribution guide"] | ||
| --- | ||
|
|
||
| ## Introduction | ||
|
|
||
| Tyk documentation is built using [Mintlify](https://mintlify.com/), a platform that allows us to create, manage and publish our documentation. | ||
| This page provides an overview and guidelines to contributing to Tyk documentation, including setting up dev environment locally, creating new content, and utilize Mintlify's [UI objects](https://mintlify.com/docs/text). | ||
|
|
||
| ## Prerequisites - applys to all flows and tasks | ||
|
|
||
| - You’ve set up the Tyk Docs local environment as described in the [Getting Started](#getting-started---running-mintlify-locally) section. | ||
| - You have a basic understanding of [Page Structure](https://mintlify.com/docs/pages) and [Navigation](https://mintlify.com/docs/navigation) in Mintlify. | ||
| - You’re familiar with Git and Markdown syntax. | ||
|
|
||
| ## Common steps for every task | ||
| - Any update requires a PR | ||
| - Please label your PR with the versions you want it to be added to | ||
| - Please assign a reviewer that is also a stakeholder who can sign off the change | ||
|
|
||
| ## Getting Started - Running Mintlify locally | ||
|
|
||
| This secion provides instructions for setting up your local environment to work with Tyk documentation using Mintlify. | ||
|
|
||
| 1. **Install Mintlify CLI globally**: | ||
| ```bash | ||
| npm install -g mintlify | ||
| ``` | ||
| 2. **Clone the Tyk Docs repository**: | ||
| ```bash | ||
| git clone https://github.com/TykTechnologies/tyk-docs.git && cd tyk-docs | ||
| ``` | ||
|
|
||
| For external contributions, you will need to fork the Tyk docs repository and clone your fork: | ||
| ```bash | ||
| git clone <fork-url> | ||
| cd tyk-docs | ||
| ``` | ||
|
|
||
| 3. **Start the Mintlify development server**: | ||
| ```bash | ||
| mintlify dev | ||
sharadregoti marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ``` | ||
| 4. Open your browser and go to `http://localhost:3000` to view the documentation. | ||
|
|
||
| ## Creating a New Page | ||
|
|
||
| To add a new page to the Tyk documentation, follow the steps below. | ||
|
|
||
| 1. **Switch to the `main` branch and pull the latest changes:** | ||
|
|
||
| ```bash | ||
| git checkout main | ||
| git pull origin main | ||
| ``` | ||
|
|
||
| 2. **Create a new branch:** | ||
|
|
||
| ```bash | ||
| git checkout -b <branch-name> | ||
| ``` | ||
|
|
||
| 3. **Create the new page:** | ||
|
|
||
| The content is organized into folders under the root directory, reflecting the website's navigation structure (tabs, groups, etc.). Choose the appropriate folder for your new page. | ||
|
|
||
| * Create a new `.mdx` file for the page. For example, for a page titled “API Versioning” you might create a file named `api-versioning.mdx`. | ||
| * Add [front matter](https://mintlify.com/docs/pages#frontmatter) to the top of the file. This is a YAML block containing metadata like the title, description, and tags. | ||
|
|
||
| **Example front matter:** | ||
|
|
||
| ```mdx | ||
| --- | ||
| title: "API Versioning" | ||
| description: "Create and manage multiple versions of an API" | ||
| sidebarTitle: "API Versioning" | ||
| tags: ['API versioning', 'version', 'Tyk Classic', 'Tyk OAS', 'API', 'versioning'] | ||
| --- | ||
|
|
||
| <Insert Lead paragraph here.> | ||
| ``` | ||
|
|
||
| * Write your content using Markdown. You can also use Mintlify UI components (e.g., accordions, callouts, code blocks) to improve readability and user experience. | ||
|
|
||
| 4. **Update `docs.json`:** | ||
|
|
||
| To make your new page appear in the navigation, update the `docs.json` file in the root directory. | ||
|
|
||
| **Example**: Adding a new page under the *"API Management"* tab in the *"Overview"* group. | ||
|
|
||
| ```json | ||
| { | ||
| ... | ||
| "navigation": { | ||
| "tabs": [ | ||
| { | ||
| "tab": "API Management", | ||
| "groups": [ | ||
| { | ||
| "group": "Overview", | ||
| "pages": [ | ||
| "tyk-overview", | ||
| "tyk-components", | ||
| "apim", | ||
| "api-versioning" // New page added here | ||
| ] | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| } | ||
| ... | ||
| } | ||
| ``` | ||
|
|
||
| 5. **Commit and push your changes:** | ||
|
|
||
| ```bash | ||
| git add -A | ||
| git commit -m "Add new page: <page-name>" | ||
| git push origin <branch-name> | ||
| ``` | ||
|
|
||
| 6. **Create a pull request** on GitHub to merge your changes into `main`. | ||
|
|
||
| Once the PR is opened, a series of automated checks will run: | ||
|
|
||
| * Link Check: Mintlify checks for broken internal links. | ||
| * Spell Check: A vale-spellcheck ensures content quality. | ||
| * Documentation Validation: A custom script checks for things like missing images and redirect conflicts. | ||
|
|
||
| 7. **Preview your changes** using the link provided by Mintlify before merging. | ||
|
|
||
| **For Contributors Outside Tyk:** A Tyk team member will need to approve the Mintlify CI build for your pull request (PR). You will need to wait | ||
| until the CI status is green. | ||
|
|
||
| **Locating Your Changes:** Since there's no search feature in this Mintlify build, you can find your changes by following these steps: | ||
| 1. **Copy the file path**: From the file path in GitHub, copy the path, excluding the `.md` file extension. | ||
| 2. **Construct the URL**: Append this copied path to the Mintlify URL after `/docs`. | ||
| 3. **Example**: To see the document at tyk-docs GitHub repository, copy `/tyk-self-managed/install` (omit `.md`) and add it after /docs/ in the Netlify URL, resulting in [https://branch-name.mintlify.app/docs/tyk-self-managed/install/](https://branch-name.mintlify.app/docs/tyk-self-managed/install/). | ||
|
|
||
| 8. **Merge to main (Updates Nightly)** | ||
|
|
||
| Once the PR is reviewed, approved, and all checks pass, it can be merged into `main`. This automatically triggers a deployment, and your changes will go live on the Nightly version of the docs. | ||
|
|
||
| 9. **Backporting to Release Versions (Cherry-Picking)** | ||
| If your change needs to be included in a stable release (e.g., v5.9): | ||
|
|
||
| 1. Go to your original, now-merged PR on GitHub. | ||
| 2. Add a label corresponding to the target version, for example, release-5.9. | ||
| 3. That's it! An automated bot (buger) will detect this label. | ||
|
|
||
| The bot will: | ||
|
|
||
| 1. Cherry-pick the commit from your original PR. | ||
| 2. Create a new PR with those changes, targeting the release-5.9 branch. | ||
| 3. Automatically merge this new PR once all checks pass. | ||
|
|
||
| The merge into the `release-5.9` branch triggers the `main` deployment workflow, which rebuilds the `production` branch. Mintlify detects the update and deploys the changes to the live v5.9 documentation. | ||
|
|
||
| ## Updating an Existing Page | ||
|
|
||
| To make changes to an existing page in the Tyk documentation, follow these steps: | ||
|
|
||
| 1. **Switch to the `main` branch and pull the latest changes:** | ||
|
|
||
| ```bash | ||
| git checkout main | ||
| git pull origin main | ||
| ``` | ||
|
|
||
| 2. **Create a new branch:** | ||
|
|
||
| ```bash | ||
| git checkout -b <branch-name> | ||
| ``` | ||
|
|
||
| 3. **Locate and edit the page:** | ||
|
|
||
| * Navigate to the appropriate folder in the repository where the `.mdx` file for the page is located. | ||
| * Open the file and make your changes using Markdown syntax. You can enhance content using Mintlify UI components like callouts, accordions, tabs, and code blocks. | ||
| * If needed, update the front matter (e.g., `title`, `description`, `tags`) at the top of the file. | ||
|
|
||
| 4. **Preview your changes locally** to ensure formatting and layout appear as expected. | ||
|
|
||
| ```bash | ||
| mintlify dev | ||
| ``` | ||
|
|
||
| 5. **Commit and push your changes:** | ||
|
|
||
| ```bash | ||
| git add . | ||
| git commit -m "<short-description-of-change>" | ||
| git push origin <branch-name> | ||
| ``` | ||
|
|
||
| 6. **Create a pull request** on GitHub to merge your branch into `main`. | ||
|
|
||
| 7. **Review the preview link** provided in the pull request to verify your changes before merging. | ||
|
|
||
| ## Deleting a Page | ||
|
|
||
| To delete a page from the Tyk documentation, follow these steps: | ||
|
|
||
| 1. **Switch to the `main` branch and pull the latest changes:** | ||
|
|
||
| ```bash | ||
| git checkout main | ||
| git pull origin main | ||
| ``` | ||
|
|
||
| 2. **Create a new branch from `main`:** | ||
|
|
||
| ```bash | ||
| git checkout -b <branch-name> | ||
| ``` | ||
|
|
||
| 3. **Delete the relevant Markdown file** corresponding to the page you want to remove. | ||
|
|
||
| 4. **Update `docs.json`:** | ||
|
|
||
| * Remove the entry for the deleted page from the `navigation` section. | ||
| * Add a redirect in the `redirect` section to point users to a relevant page. This prevents 404 errors when the deleted page is accessed. | ||
|
|
||
| 5. **Commit and push your changes:** | ||
|
|
||
| ```bash | ||
| git add . | ||
| git commit -m "Delete page: <page-name> - <Explain briefly the reason>" | ||
| git push origin <branch-name> | ||
| ``` | ||
|
|
||
| 6. **Create a pull request** on GitHub to merge your branch into `main`. | ||
|
|
||
| 7. **Review the preview link** provided by Mintlify to ensure your changes appear as expected before merging. | ||
|
|
||
| ## Guide for UI features | ||
|
|
||
| Apart from the basic markdown writing, Tyk documentation also support UI components like accordions, callouts, cards, expandables, tabs etc. These components help in enhance the documentation's usability and readability. | ||
|
|
||
| Here's a table summarizing the UI features available for Tyk documentation: | ||
|
|
||
| | Name | Description | | ||
| |------|-------------| | ||
| | [Code Blocks](https://mintlify.com/docs/code) | Display inline code and code blocks | | ||
| | [Accordions](https://mintlify.com/docs/components/accordions) | A dropdown component to toggle content visibility | | ||
| | [Callouts](https://mintlify.com/docs/components/callouts) | Use callouts to add eye-catching context to your content | | ||
| | [Cards](https://mintlify.com/docs/components/cards) | Highlight main points or links with customizable icons | | ||
| | [Expandables](https://mintlify.com/docs/components/expandables) | Toggle to display nested properties. | | ||
| | [Tabs](https://mintlify.com/docs/components/tabs) | Toggle content using the Tabs component | | ||
| | [Mermaid](https://mintlify.com/docs/components/mermaid-diagrams) | Display diagrams using Mermaid | | ||
| | [Steps](https://mintlify.com/docs/components/steps) | Sequence content using the Steps component | | ||
| | Snipptet | A custom component written by us. TODO | | ||
|
|
||
| **Note:** The above components is a list of mostly used components in Tyk documentation. To see the complete list of components, refer to the [Mintlify documentation](https://docs.mintlify.com/docs/components). | ||
|
|
||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.