Skip to content

Commit

Permalink
Merge pull request #280 from Crequency/dev=main
Browse files Browse the repository at this point in the history
[Pull Request] Allow pass command when manually invoke `Actions.PublishPackages`
  • Loading branch information
Dynesshely authored Feb 28, 2024
2 parents 5dae325 + 38ddb6f commit b5b071c
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions .github/workflows/publish-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,16 @@ on:
branches: ["main"]

workflow_dispatch:
inputs:
command:
description: "Command"
default: "[Publish Packages][All]"

jobs:
build-on-ubuntu:
runs-on: ubuntu-latest
environment: Publish Packages
if: contains(github.event.head_commit.message, '[Publish Packages]')
if: contains(github.event.head_commit.message, '[Publish Packages]') || contains(github.event.inputs.command, '[Publish Packages]')

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -45,7 +49,7 @@ jobs:

- name: Build and Publish `Cheese`
working-directory: "KitX SDK/Cheese"
if: contains(github.event.head_commit.message, '[Cheese]') || contains(github.event.head_commit.message, '[All]')
if: contains(github.event.head_commit.message, '[Cheese]') || contains(github.event.head_commit.message, '[All]') || contains(github.event.inputs.command, '[Cheese]') || contains(github.event.inputs.command, '[All]')
run: |
dotnet build -c Release
Expand All @@ -54,7 +58,7 @@ jobs:
- name: Build and Publish `KitX.Contract.CSharp`
working-directory: "KitX Standard/KitX Contracts/KitX.Contract.CSharp"
if: contains(github.event.head_commit.message, '[KitX.Contract.CSharp]') || contains(github.event.head_commit.message, '[All]')
if: contains(github.event.head_commit.message, '[KitX.Contract.CSharp]') || contains(github.event.head_commit.message, '[All]') || contains(github.event.inputs.command, '[KitX.Contract.CSharp]') || contains(github.event.inputs.command, '[All]')
run: |
dotnet build -c Release
Expand All @@ -63,7 +67,7 @@ jobs:
- name: Build and Publish `KitX.Shared.CSharp`
working-directory: "KitX Standard/KitX Shared/KitX.Shared.CSharp"
if: contains(github.event.head_commit.message, '[KitX.Shared]') || contains(github.event.head_commit.message, '[All]')
if: contains(github.event.head_commit.message, '[KitX.Shared.CSharp]') || contains(github.event.head_commit.message, '[All]') || contains(github.event.inputs.command, '[KitX.Shared.CSharp]') || contains(github.event.inputs.command, '[All]')
run: |
dotnet build -c Release
Expand All @@ -72,7 +76,7 @@ jobs:
- name: Build and Publish `KitX.FileFormats.CSharp`
working-directory: "KitX Standard/KitX File Formats/KitX.FileFormats.CSharp"
if: contains(github.event.head_commit.message, '[KitX.FileFormats]') || contains(github.event.head_commit.message, '[All]')
if: contains(github.event.head_commit.message, '[KitX.FileFormats.CSharp]') || contains(github.event.head_commit.message, '[All]') || contains(github.event.inputs.command, '[KitX.FileFormats.CSharp]') || contains(github.event.inputs.command, '[All]')
run: |
dotnet build -c Release
Expand Down

0 comments on commit b5b071c

Please sign in to comment.