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

Modularize path.lua into basename.lua and directory.lua #10

Open
Ambrevar opened this issue Jan 28, 2018 · 3 comments
Open

Modularize path.lua into basename.lua and directory.lua #10

Ambrevar opened this issue Jan 28, 2018 · 3 comments

Comments

@Ambrevar
Copy link
Owner

As mentioned here, it would give more flexibility to the user.

path.lua would remain for backward compatibility and simply enable the other two.

@fictionic
Copy link

fictionic commented Jan 29, 2018

Note that my path.lua does more than simply enable basename.lua and directory.lua—it also deals with the output file extension (including setting it to any override value provided by the user), and takes care of the weird ffmpeg mp4 subformat behavior (you probably don't want an audio file with a mov extension, for example)

In fact, in my setup, if path.lua is not run, then neither of the other two path-related scripts will have an effect. path.lua is the master script for determining the output path; basename.lua and directory.lua are toggleable. You would only disable path.lua if you wanted to ensure that the operation was in-place (since the default for output.path is input.path).

@Ambrevar
Copy link
Owner Author

it also deals with the output file extension (including setting it to any override value provided by the user), and takes care of the weird ffmpeg mp4 subformat behavior (you probably don't want an audio file with a mov extension, for example)

Why not moving this to basename.lua?

@fictionic
Copy link

Why not moving this to basename.lua?

Because, while I admit that the word "basename" means "the file path minus the directory", and thus includes the extension, I think that generally users want the correct file extension on their files; or, if they don't, it's not related to their desires about the rest of the basename. Basically, I want people to be able to disable basename without preventing the correct extension from being set.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants