Skip to content

(messages) better class splitting in PHP version #1894

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

Merged

Conversation

ciaranmcnulty
Copy link
Contributor

Remove the PHP script responsible for message class splitting

#1879 introduced a better csplit-driven approach in the Java version, so copying it (and fixing a minor error)

There is a better approach in the Java version, so copying it (and fixing a minor error)
@ciaranmcnulty ciaranmcnulty force-pushed the messages-php-better-splitting branch from d6ea673 to a005d73 Compare February 5, 2022 16:20
csplit --quiet --prefix=build/Generated --suffix-format=%02d.php.tmp --elide-empty-files build/messages.php /^.*[.]php$$/ {*}
rm build/messages.php
rm -rf src-generated/*
for file in build/Generated**; do mkdir -p src-generated/$$(head -n 1 $$file | sed 's/[^/]*.php$$//'); done
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is required to make the subfolders - the sed ends up trying to make src-generated/ a bunch of times but I think it's harmless

@aurelien-reeves
Copy link
Contributor

Nice :D

@ciaranmcnulty ciaranmcnulty enabled auto-merge (squash) February 8, 2022 09:55
@ciaranmcnulty ciaranmcnulty merged commit cae8870 into cucumber:main Feb 8, 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.

2 participants