Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Allow arbitrary file for script_dirs #8

Open
Haegi opened this issue May 5, 2021 · 6 comments · May be fixed by #17
Open

Allow arbitrary file for script_dirs #8

Haegi opened this issue May 5, 2021 · 6 comments · May be fixed by #17

Comments

@Haegi
Copy link
Contributor

Haegi commented May 5, 2021

Motivation

At the moment it is only possible to import local .sh and .py files via the script_dirs argument due to this condition.
It would be great to be able to import any local file or at least .yaml files for ytt.

Ideas

  • Add a argument called file_types to the Pipeline class
  • Add .yaml to the condition
  • Accept every file (but I don't think that this is the right way)
@Haegi
Copy link
Contributor Author

Haegi commented May 10, 2021

@phil9909 @loewenstein @c0d1ngm0nk3y WDYT?

@phil9909
Copy link
Contributor

Add a argument called file_types to the Pipeline class

+1

@loewenstein
Copy link
Contributor

file_types would be independent from script_dirs? Sounds strange. What about changing to scripts and supporting globs?

@c0d1ngm0nk3y
Copy link
Contributor

Add a argument called file_types to the Pipeline class

+1

I think I got it now. So [".sh", ".py"] could be the default.

+1

@c0d1ngm0nk3y
Copy link
Contributor

file_types would be independent from script_dirs?

But I think it is unlikely that we need different file_types for each script_dir, right?

@Haegi
Copy link
Contributor Author

Haegi commented Jun 2, 2021

The approach of @c0d1ngm0nk3y looks quite good.
However, I like the globbing approach much more and I opened #17 to get a first idea of how it could be done.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
4 participants