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

Strictness of user env variable when used as paths #47

Open
KaruroChori opened this issue Dec 7, 2024 · 0 comments
Open

Strictness of user env variable when used as paths #47

KaruroChori opened this issue Dec 7, 2024 · 0 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@KaruroChori
Copy link
Owner

          This issue is strictly related to the specs & implementation of the function in `https://github.com/KaruroChori/vs-fltk/pull/21`.  

It is intended behaviour due to an internal convention for paths being used as base, and generated by the normalizer:

  • Paths ending with / are normalized paths where the last token is a directory
  • Paths not ending with / are normalized paths where the last token is a file (which can be stripped in several cases)

Even if a bit annoying, this is generally fine as users are not allowed to inject paths from the outside.
However I did an exception for some injected values via env variables.
Yet, paths injected via those variables must follow those same rules to work properly.

As they are user-facing, either this has to be well documented, or I should have a more tolerant sanitation for env variables to prevent situations like this one.

Originally posted by @KaruroChori in #20 (comment)

@KaruroChori KaruroChori added documentation Improvements or additions to documentation enhancement New feature or request labels Dec 7, 2024
@KaruroChori KaruroChori self-assigned this Dec 7, 2024
andy5995 added a commit to andy5995/vs-fltk that referenced this issue Dec 7, 2024
Related to KaruroChori#47

This sets the default shell for 'builder' to '/bin/bash'.

When using 'meson devenv', the prompt becomes "[vs-fltk]
builder@0884a9be3841:/vs-workspace/build$" instead of "?" now.

Although that doesn't really improve anything except cli editing, as
I've moved the variables to the entrypoint scripts, and therefore devenv
isn't needed if using the docker container.

This also fixes this annoying message when starting the container:

bash: cannot set terminal process group (14): Inappropriate ioctl for
device
bash: no job control in this shell
builder@b7d17feb7490:~$
KaruroChori added a commit that referenced this issue Dec 8, 2024
Related to #47

This sets the default shell for 'builder' to '/bin/bash'.

When using 'meson devenv', the prompt becomes "[vs-fltk]
builder@0884a9be3841:/vs-workspace/build$" instead of "?" now.

Although that doesn't really improve anything except cli editing, as
I've moved the variables to the entrypoint scripts, and therefore devenv
isn't needed if using the docker container.

This also fixes this annoying message when starting the container:

bash: cannot set terminal process group (14): Inappropriate ioctl for
device
bash: no job control in this shell
builder@b7d17feb7490:~$

Co-authored-by: KaruroChori <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant