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

Finalize string vs array glob paths #3

Open
richrdkng opened this issue May 25, 2016 · 0 comments
Open

Finalize string vs array glob paths #3

richrdkng opened this issue May 25, 2016 · 0 comments
Labels
Milestone

Comments

@richrdkng
Copy link
Contributor

richrdkng commented May 25, 2016

When storing and returning named glob paths, finalize the stored/returned form of glob paths.

Suggested Features:

- 1.:
Add the built-in behavior of automatic string/array determination, so when there is only 1 glob path under a given name, the glob path will be a string. Otherwise, when adding glob paths to that given name or remove from its glob paths, when there is more, than 1 glob paths, store and handle the glob paths as arrays.

Important: Finalize this behavior module-wise, meaning, when a particular stored glob path is an array, when returning it from functions, if it is stored as an array, return it too as an array.

Also extend the tests to test this behavior.

- 2.:
Add the ability to be able to define custom behavior, meaning, that the user be able to define, what glob path storage/return behavior should be used, e.g.:

Paths.setGlobBehavior(Paths.HANDLE_GLOB_AS_STRING);

// OR

Paths.setGlobBehavior(Paths.HANDLE_GLOB_AS_ARRAY);

// OR

Paths.setGlobBehavior(Paths.HANDLE_GLOB_DYNAMICALLY);

Note: When glob handling is strictly set to HANDLE_GLOB_AS_STRING, throw error, when, by functionality, glob paths must be extended to arrays (e.g.: when appending to glob paths).

@richrdkng richrdkng added this to the 1.0 milestone May 25, 2016
@richrdkng richrdkng modified the milestones: 3.0, 2.0 Sep 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant