Skip to content

[BUG] Spaces in file names are not handled correctly #216

Closed
@vertxxyz

Description

@vertxxyz

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug?

If you have spaces in your file names and you provide a custom separator (eg. separator: ",") all spaces are replaced by the separator and the results sorted.

To Reproduce

  1. On a repo containing the paths:
  • embeds/general 412874536418279426/read-me-1 899830563651854336.json
  • Test 1/Test 1.json
  1. Running
- id: json_changes
  uses: tj-actions/[email protected]
  with:
      files: |
        .json$
      separator: ","

- name: List modified files
  run: |
    echo ${{ steps.json_changes.outputs.all_modified_files }}
  1. Sees the result of:
    1.json,1/Test,412874536418279426/read-me-1,899830563651854336.json,Test,embeds/general

What OS are you seeing the problem on?

ubuntu-latest or ubuntu-20.04

Expected behavior?

I expect:
embeds/general 412874536418279426/read-me-1 899830563651854336.json,Test 2/Test 1.json

Relevant log output

No response

Anything else?

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions