About 440,000 results
Open links in new tab
  1. Evaluate expressions in workflows and actions - GitHub Docs

    Instead of writing github.event_name == "push" || github.event_name == "pull_request", you can use contains() with fromJSON() to check if an array of strings contains an item. For example, …

  2. github actions - Conditional to check if a string is included in a

    Jan 10, 2021 · Returns true if search contains item. If search is an array, this function returns true if the item is an element in the array. If search is a string, this function returns true if the item is a …

  3. How to use a context variable with contains () in an if: line ... - GitHub

    Mar 9, 2022 · I saw a post on a forum saying that you don’t actually need to use $ { { }} in if because it just knows it’s an expression and access context variables, so I tried both with and without curly …

  4. Accessing contextual information about workflow runs - GitHub Docs

    The github context contains information about the workflow run and the event that triggered the run. You can also read most of the github context data in environment variables.

  5. GitHub Actions If contains function not working with env.VARIABLE

    Apr 16, 2020 · Using "set-env" has been deprecated by Github. The set-env command is disabled. Please upgrade to using Environment Files or opt into unsecure command execution by setting …

  6. GitHub Actions Essentials: What are expressions in ... - Medium

    Dec 4, 2023 · GitHub offers a set of built-in functions that you can use in expressions. Returns true if search contains item. Example: contains('welcome', 'co') returns true. Returns true when …

  7. Have actions *not* run a job if a label is set - GitHub

    Jun 22, 2020 · After staring at the GitHub API docs, labels is an array, which means contains seems to be looking for a “full string” (as it were) not just something in the string.

  8. GitHub Actions Cheat Sheet

    Mar 31, 2025 · GitHub's documentation has caught up with the provided features and became a lot better: https://docs.github.com/en/actions. Reference: …

  9. Using conditions to control job execution - GitHub Docs

    In some parts of the workflow you cannot use environment variables. Instead you can use contexts to access the value of an environment variable. For more information, see Store information in …

  10. In a GitHub Action how to conditionalize a step based off the …

    May 3, 2022 · Building a GitHub action based on the commit message I'm trying to base a step on whether the commit message contains a particular string, set it to a variable and then in the next …

  11. Some results have been removed
Refresh