Skip to content

A github action to create a project version in MantisHub.

Notifications You must be signed in to change notification settings

mantishub/action-create-version

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

MantisHub Create Version GitHub Action

This is an action that will often be triggered when a new tag is applied to the repo. For example, when a tag is added, create a version in MantisHub for the release.

Usage

To use this action in your GitHub workflow, add the following step to your workflow file:

The defaults for field are:

  • released defaults to true.
  • obsolete defaults to false.
  • timestamp defaults to now.
jobs:
  create-version:
    runs-on: ubuntu-latest
    steps:
      - name: Check out code
        uses: actions/checkout@v4
        with:
          repository: mantishub/action-create-version
      - name: Create Version Action
        id: create-version
        uses: mantishub/action-create-version@v1
        with:
          url: https://example.mantishub.io
          api-key: ${{ secrets.API_KEY }}
          project: 'MyProject'
          name: 'v1.1.13'
          description: |
            Release Version 1.1.13
            For bugs fixes
          released: false
          obsolete: true
          timestamp: '2025-09-20'

Example workflow file

This workflow demonstrates how to use the action-create-version in a GitHub Actions workflow to create a new version in a MantisHub project. The workflow checks out the code, runs the custom action, and retrieves the new version.

In the workflow below, the step Create Version Action is assigned the ID create-version. Later, the output version-id generated by this step can be accessed using the syntax ${{ steps.create-version.outputs.version-id }} in the Get new version id step.

name: "MantisHub Example Workflow"

on:
  workflow_dispatch:
jobs:
  create-version:
    runs-on: ubuntu-latest
    steps:
      - name: Check out code
        uses: actions/checkout@v4
        with:
          repository: mantishub/action-create-version
      - name: Create Version Action
        id: create-version
        uses: mantishub/action-create-version@v1
        with:
          url: 'https://example.mantishub.io'
          api-key: {{some-token}}
          project: 'MyProject'
          name: 'v1.1.13'
          description: |
            Release Version 1.1.13
            For bugs fixes
          released: false
          obsolete: true
          timestamp: '2025-09-20'
      - name: Get new version id 
        run: echo  ${{ steps.create-version.outputs.version-id }}

About

A github action to create a project version in MantisHub.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published