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

Extract all supported functions. #13

Merged
merged 6 commits into from Jan 22, 2018

Conversation

3 participants
@gitlost
Copy link
Contributor

gitlost commented Jan 13, 2018

See #12 (comment)

Renames function map names to be more meaningful in WordPress_Code_Extractor and supports all in WordPress_Functions_Scanner::saveGettextFunctions() and errors if unmapped found.

Also errors if comments_number_link() found (not sure what to do here).

Adds tests.

@gitlost

This comment has been minimized.

Copy link
Contributor Author

gitlost commented Jan 13, 2018

@swissspidy

This comment has been minimized.

Copy link
Member

swissspidy commented Jan 22, 2018

Hmm. I simply copied comments_number_link() from the existing makepot.php file. Turns out, this isn't even an existing function in WordPress. At least not anymore.

It was added to the script over seven years ago in https://i18n.trac.wordpress.org/changeset/15325. I guess it's a remnant from the earlier days of WordPress.

We should remove it from this script as it serves no purpose.

@swissspidy

This comment has been minimized.

Copy link
Member

swissspidy commented Jan 22, 2018

Actually, I think we can remove support for _n_js() and _nx_js() as well since they don't exist in WordPress.

These functions were added to makepot.php in https://i18n.trac.wordpress.org/changeset/20807 to test patches for the #22229 ticket in WordPress core. I used the same function in another patch for #20491.

We can remove them now and re-add them as soon as they actually exist. However, I don't think these functions will ever make it to core in that form

swissspidy added some commits Jan 22, 2018

@swissspidy swissspidy requested a review from wp-cli/committers Jan 22, 2018

@swissspidy swissspidy referenced this pull request Jan 22, 2018

Closed

Decide on command name #11

@schlessera schlessera merged commit 3771364 into master Jan 22, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@schlessera schlessera deleted the functions-fix branch Jan 22, 2018

@schlessera schlessera added this to the 0.1.0 milestone Jan 22, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.