Skip to content
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

Accessing variable in format() method gives an error. #1902

Open
VictorGhevondyan opened this issue Dec 11, 2024 · 0 comments
Open

Accessing variable in format() method gives an error. #1902

VictorGhevondyan opened this issue Dec 11, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@VictorGhevondyan
Copy link

VictorGhevondyan commented Dec 11, 2024

Describe the bug
Accessing variable in format() method gives an error.

To Reproduce
Steps to reproduce the behavior:

  1. Write a similar step in GitHub Action job:

    • name: Output variable
      run: |
      my_variable ='blabla'
      echo ${{ format('startOfString{0}', $my_variable ) }}
      shell: bash
  2. Run corresponding GitHub Action

  3. See error :
    "The workflow is not valid. .github/workflows/my_workflow_file.yml (Line: a, Col: b): Unexpected symbol: '$my_variable'. Located at position... "

Expected behavior
String with substituted value should be printed .

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [Windows]
  • Browser [Microsoft Edge]
  • Version [131]
@VictorGhevondyan VictorGhevondyan added the bug Something isn't working label Dec 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant