Skip to content

Add @ to allowed separators of version_variables #1156

Closed
@benedikt-hess-km

Description

@benedikt-hess-km

Feature Request

Description

Currently, when defining version variables with the version_variables configuration parameter, the versions in the specified files, have to be preceded by :, = or :=.

See

I would like to add the @ to the allowed separators, as it is used in gitHub actions ymls.

Use cases

I have a github repo (e.g. my-org/my-actions) containing multiple actions:

my-actions/.github/workflows/
        action1.yml
        action2.yml
        combined.yml

action1.yml and action2.yml are both called by combinded.yml

on:
  workflow_call:
jobs:
  action1:
    uses: my-org/my-actions/.github/workflows/action1.yml@v1.2.3
  action2:
    uses: my-org/my-actions/.github/workflows/action2.yml@v1.2.3

Currently there is no way for PSR to update the two versions in the combined.yml file.

Possible implementation

change line to r"\s*(:=@|[:=])\s*",

Metadata

Metadata

Assignees

No one assigned

    Labels

    confirmedPrevent from becoming stalefeatureA new feature or a feature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions