https://github.com/compas-dev/compas-actions.docversions
https://github.com/compas-dev/compas-actions.docversions
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/compas-dev/compas-actions.docversions
- Owner: compas-dev
- Created: 2021-04-13T08:08:39.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2024-01-25T09:26:52.000Z (about 2 years ago)
- Last Synced: 2025-01-19T10:45:23.681Z (about 1 year ago)
- Language: JavaScript
- Size: 298 KB
- Stars: 0
- Watchers: 6
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# compas-actions.docversions
## Introduction
`compas-actions.docversions` is a GitHub action designed to update the documentation versions list for COMPAS repositories. It automates the process of maintaining a current list of documentation versions, ensuring users have access to the latest and relevant documentation. This action is designed to be used internally inside the `compas-actions.docs` action. Please refer to the [compas-actions.docs](https://github.com/compas-dev/compas-actions.docs) documentation for more information.
## Usage
To use this action in your workflow, include it in your `.yml` file with the required inputs.
```yaml
steps:
- uses: your-repo/compas-actions.docversions@v3
with:
doc_url:
only_keep_latest_patch: 'true' # or 'false' to keep each patch version.
```
This action will update the `versions.json` file repository with the latest versions list. It will also remove older `patch` and `pre-release` versions of each `minor` version if `only_keep_latest_patch` is set to `true`.
## Development
To develop this action, you will need to have `node` and `npm` installed. You can install them by following the instructions [here](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm).
### Install dependencies
```bash
npm install
```
### Build
To build the action you need ncc to compile `index.js`.
```bash
npm install -g @vercel/ncc
```
Then remember to build the action before committing.
```bash
npm run build
```