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

Permit the '@' character in filenames #684

Closed
wants to merge 1 commit into from

Conversation

floppym
Copy link
Contributor

@floppym floppym commented Jun 2, 2024

This will allow for systemd template units to be stored in files/ without mangling the filename.

PMS says nothing about filenames in files/ so we can really permit whatever we find palatable.

@floppym floppym force-pushed the banned-character-filesdir branch 2 times, most recently from a98b422 to 5efad2d Compare June 2, 2024 00:32
@ulm
Copy link
Contributor

ulm commented Jun 2, 2024

The charset in the repo is based on the POSIX Portable Filename Character Set, with the addition of the plus sign.

IIRC this was discussed in QA at some point because there were files with problematic characters like &.

https://devmanual.gentoo.org/general-concepts/tree/index.html#what-belongs-in-the-tree

@floppym
Copy link
Contributor Author

floppym commented Jun 2, 2024

The charset in the repo is based on the POSIX Portable Filename Character Set, with the addition of the plus sign.

As I have said before, that character set is overly restrictive. It excludes many characters that work just fine on the platforms Gentoo targets.

IIRC this was discussed in QA at some point because there were files with problematic characters like &.

The line "Files whose name contains characters outside [A-Za-z0-9._+-]" was added to the devmanual by you in this commit.

https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=57f7cae438731c26130d8f45e12572e727185189

It references the "status quo", not any QA decision.

@floppym floppym force-pushed the banned-character-filesdir branch 3 times, most recently from 5621778 to 4526684 Compare June 2, 2024 05:40
@floppym floppym changed the title Permit any printable ASCII character in files/ Permit '@' character in files/ Jun 2, 2024
@floppym floppym changed the title Permit '@' character in files/ Permit the '@' character in files/ Jun 2, 2024
@ulm
Copy link
Contributor

ulm commented Jun 2, 2024

IIRC this was discussed in QA at some point because there were files with problematic characters like &.

The line "Files whose name contains characters outside [A-Za-z0-9._+-]" was added to the devmanual by you in this commit.

https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=57f7cae438731c26130d8f45e12572e727185189

It references the "status quo", not any QA decision.

To clarify, not necessarily an official QA decision, but it was discussed. I certainly didn't add that bullet point without getting consensus.

At the time it was also a no-brainer because a) it reflected the status of the tree, and b) the rationale for the POSIX charset was that it was already mentioned elsewhere in the devmanual (this has been there since 2005, in ciaranm's RST version). So, not much thought was given to addition of other characters.

This will allow for systemd template units to be stored in files/
without mangling the filename.

Signed-off-by: Mike Gilbert <floppym@gentoo.org>
@floppym floppym force-pushed the banned-character-filesdir branch from 4526684 to dafbba6 Compare June 2, 2024 15:43
@floppym floppym changed the title Permit the '@' character in files/ Permit the '@' character in filenames Jun 2, 2024
@floppym
Copy link
Contributor Author

floppym commented Jun 2, 2024

To clarify, not necessarily an official QA decision, but it was discussed.

Yeah, I get triggered by undocumented QA decisions. I'm sure it was discussed by some people, but without a record of it I have no context.

In the interest of keeping things simple/consistent, I added '@' to the existing set of permitted characters and dropped the separate set specific to files/. If that is undesirable, I can revert back.

@floppym
Copy link
Contributor Author

floppym commented Jun 2, 2024

Also for the purposes of documentation, this devmanual PR was merged today. gentoo/devmanual#339

@ulm
Copy link
Contributor

ulm commented Jun 2, 2024

Should the git hook allow @ also for directory names? Currently it doesn't:
https://cgit.gentoo.org/infra/githooks.git/commit/local?id=e24eacaa31707ef669cd5a9747a1bf08a5759fdf

@floppym
Copy link
Contributor Author

floppym commented Jun 2, 2024

I'm giving up on this for now. This QA check is coded in too many places and I'm just too frustrated at this point.

@floppym floppym closed this Jun 2, 2024
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

Successfully merging this pull request may close these issues.

2 participants