8000 feat(regexp-assemble): Update data file comment by theseion · Pull Request #2565 · coreruleset/coreruleset · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat(regexp-assemble): Update data file comment #2565

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

Closed

Conversation

theseion
Copy link
Contributor

The header comment in the regexp-assemble data files was no longer in
sync with the implementation after the merge of the improvements to the
preprocessing engine of regexp-assemble.

Replaces #2545 (comment) for v4.1/dev

The header comment in the regexp-assemble data files was no longer in
sync with the implementation after the merge of the improvements to the
preprocessing engine of regexp-assemble.
@theseion theseion force-pushed the update-data-file-comments branch from 0a12c52 to 2f3e257 Compare May 23, 2022 19:13
@theseion theseion force-pushed the update-data-file-comments branch from 2f3e257 to 234ab19 Compare May 24, 2022 04:34
@theseion
Copy link
Contributor Author

We have been discussing about dropping the header from the regexp-assemble data files. The header explains some basics but obviously leaves out a lot. The issue is that the header changes from time to time and every time it does we need to update 20+ files.

For anyone interested in the matter, please with 🗑️ (trash) for "trashing" the header or with 📜 (scroll) for keeping it.

@dune73
Copy link
Member
dune73 commented May 24, 2022

🗑️

@fzipi
Copy link
Member
fzipi commented May 24, 2022

🗑️ (the emoji is called "wastebasket" in my case) 🤷

@dune73
Copy link
Member
dune73 commented May 24, 2022

I just copy & pasted his 🗑️.

@RedXanadu
Copy link
Member
RedXanadu commented May 24, 2022

The beauty of the header is that it is clear and easy to read in plain text.

Is the alternative to rely on README.MD? The problem with that is the file is difficult to read at the CLI. (I'm sure some of us don't want to fire up a web browser just to read README.MD when we're editing regex data files 🙂)

I'd still vote to bin it and centralise the header info, though 🗑️ (bin)

@fzipi
Copy link
Member
fzipi commented May 24, 2022

I was just thinking of plain text, as it is now, and call it README.data.

@theseion
Copy link
Contributor Author

Why is it difficult to read? Most editors have highlighting for markdown.

@theseion
Copy link
Contributor Author

🗑️ (the emoji is called "wastebasket" in my case) 🤷

I just copy & pasted his 🗑️.

You can type :trash and it will show you the wastebasket emoji.

@lifeforms
Copy link
Member

🗑️

@RedXanadu
Copy link
Member

@theseion It looks like a mess due to the formatting. Looks lovely in HTML, but a mess at the CLI. Compared to the header in each .data file, which is written in plain text and easy to read and understand.

@theseion
Copy link
Contributor Author

@RedXanadu

brew install ronn && ronn -m util/regexp-assemble/README.md

Or I can generate the man page, put it beside the markdown file and you could do

man util/regexp-assemble/README.1

Would that help?

@theseion
Copy link
Contributor Author
theseion commented May 25, 2022

@RedXanadu here's the README with formatting that can be properly formatted by ronn. Doesn't look too bad :)

README.md

@RedXanadu
Copy link
Member
RedXanadu commented May 25, 2022

Yeah, we can make it look pretty, I was just making the point that the existing headers are good because they are easy to read in plain text already.

We can make the README file look nice in a PDF or as HTML, of course, but we're sacrificing the plain text readability of the existing headers by removing them.

I still think it is a good idea centralise/remove the headers, as suggested, I just wanted to raise the point :)

@theseion
Copy link
Contributor Author

Fair enough :)

Thanks everyone for voting. I will close this PR and open a new one to remove the headers.

@theseion theseion closed this May 26, 2022
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.

5 participants
0