0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

Github Actions : snake case to kebab case

Last updated at Posted at 2022-11-09

簡単なことなんですが、めちゃはまったので。。。

snake_case って文字が snake-case なります

name: snake case to kebab case smple

on:
  workflow_dispatch:
    inputs:
      input_string:
        description: 'select input string'
        required: true
        type: choice
        default: 'snake_case'
        options:
        - snake_case
        - kebab-case
          
jobs:
  CaseChange:
    runs-on: ubuntu-latest
    steps:
      - name: echo input
        run : |
          echo ${{ inputs.input_string }}
      - name: snake case to kebab case
        run: |
          echo "KebabCase=${{ inputs.input_string }}" | sed $'s/_/-/g' >> $GITHUB_ENV
      - name: use kebab case
        run: |
          echo ${{ env.KebabCase }}

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?