Giter Club home page Giter Club logo

Comments (5)

jackton1 avatar jackton1 commented on June 10, 2024 1

Given the unique use case I’ve added support for setting the outputs to true but noting that it would only be false if a pattern is specified.

from changed-files.

tj-actions-bot avatar tj-actions-bot commented on June 10, 2024

Thanks for reporting this issue, don't forget to star this project if you haven't already to help us reach a wider audience.

from changed-files.

jackton1 avatar jackton1 commented on June 10, 2024

Hi @AndreyNautilus, to clarify the any_{changed, modified} outputs. As highlighted in the documentation, requires at least one file pattern.

any_changed string Returns true when any of the filenames provided using the files or files_ignore inputs have changed. i.e.includes a combination of all added, copied, modified and renamed files (ACMR).

Note

The filePatterns array mentioned comprises of ignored and included file/directory patterns and at least one pattern needs to be provided.

If you intend to have an empty file passed to the files_ignore_from_source_file input in such a scenario both outputs would remain false.

The any in the context of the output specifically means "any of the files I want to filter" which doesn't apply to cases when no filters are specified.

I hope that clears things up.

from changed-files.

AndreyNautilus avatar AndreyNautilus commented on June 10, 2024

@jackton1 thanks for the explanation.
Then the documentation is a bit confusing. As you pointed out the description for the output says:

Returns true when any of the filenames provided using the files or files_ignore inputs have changed

while the description for files input says:

File and directory patterns used to detect changes (Defaults to the entire repo if unset).

Which makes an impression that if files input is omitted, it defaults to something like **, and that should make any_changed/any_modified outputs true.

I agree with "not a bug" resolution, but it seems the documentation should be a bit more accurate.

from changed-files.

AndreyNautilus avatar AndreyNautilus commented on June 10, 2024

Thank you for the fix!

from changed-files.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.