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

wp-cli-comform command #705

Merged
merged 5 commits into from Apr 2, 2015
Merged

wp-cli-comform command #705

merged 5 commits into from Apr 2, 2015

Conversation

szepeviktor
Copy link
Contributor

Adding line comments...

@@ -1,6 +1,6 @@
<?php
/**
* Stream commands for WP-CLI
* Stream command for WP-CLI
Copy link
Contributor Author

Choose a reason for hiding this comment

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

only one


$start = microtime( true );
$query_args = array();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

removed timer, a wp-cli user is advanced enough to know what is happening, and why it takes time

Copy link
Contributor

Choose a reason for hiding this comment

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

@szepeviktor Fair enough. Better results can be seen with the time command anyway.

$ time wp stream query

@szepeviktor
Copy link
Contributor Author

This must have an least one error. Please review.

@szepeviktor
Copy link
Contributor Author

Has a very nice output. Do you need csv, json and count output?

+------------------------------+----------------+--------+------------------------+---------------+------------------------------------+
| created                      | ip             | author | author_meta.user_login | author_role   | summary                            |
+------------------------------+----------------+--------+------------------------+---------------+------------------------------------+
| 2015-02-25T18:07:20.709+0000 | 192.168.12.146 | 1      | viktor                 | administrator | "1" post published                 |
| 2015-02-25T18:07:18.045+0000 | 192.168.12.146 | 1      | viktor                 | administrator | "1" post drafted                   |
| 2015-02-25T18:04:51.063+0000 | 192.168.12.146 | 1      | viktor                 | administrator | "What's running" plugin activated  |
| 2015-02-25T18:04:01.200+0000 | 192.168.12.146 | 1      | viktor                 | administrator | Site connected to Stream           |
+------------------------------+----------------+--------+------------------------+---------------+------------------------------------+

*included

@szepeviktor
Copy link
Contributor Author

I am OK if you reject it. It could also be a separate wp-cli community command.
I've done these modifications based on the wp-cli contributor experience.
I hope it will not hurt any of you.

@szepeviktor szepeviktor mentioned this pull request Feb 25, 2015
@fjarrett
Copy link
Contributor

@szepeviktor Just a few CI errors to take note of: https://travis-ci.org/wp-stream/stream/jobs/52189700#L890

@szepeviktor
Copy link
Contributor Author

Was it CodeSniffer?

@szepeviktor
Copy link
Contributor Author

I've done it for free. Could you give me a trial PRO licence?

@szepeviktor
Copy link
Contributor Author

All green.

@fjarrett
Copy link
Contributor

Thanks @szepeviktor. We are using the WordPress Coding Standards project to enforce coding style, which uses PHP_CodeSniffer.

Absolutely, please e-mail me your Stream Site ID frankie@wp-stream.com

fjarrett added a commit that referenced this pull request Apr 2, 2015
@fjarrett fjarrett merged commit 147029d into xwp:develop Apr 2, 2015
@fjarrett
Copy link
Contributor

fjarrett commented Apr 2, 2015

@szepeviktor Nicely done! Thanks for these many improvements. Please do shoot me an email when you can.

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.

None yet

2 participants