Announcing a new plugin for Rules.
It addes "developer comments" to Rules graphical language.

Sandbox link: http://drupal.org/sandbox/onkeltem/1719474

Initially I intended to call it just "Rules Comment" (and "comment" - in code), but after collecting some statistics in Rules' issue queue I thought this would produce misunderstanding, since "comment" most frequently means user comment from Drupal.
For this reason I called it "ui_comment" and under that name it is seen in UI.
I'm not sure anymore what name suits more, but now I dislike "ui_comment" too, thinking about changing name to "dev_comment".
Finally, I've come up to the feeling that I dislike any variant except "comment", since I want it to show up in UI exactly under this name: "add comment".
Unfortunately, Rules display "code" names in UI, not "titles" so I'm tied to use same name for UI and code.
Feedback is welcome.
Is it ok if I rename it to just "comment"?

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

OnkelTem’s picture

Title: Rules Plugin » Rules Developer Comment Plugin
OnkelTem’s picture

Issue summary: View changes

Updated issue summary.

timb’s picture

I'd like to see this functionality to make rules more readable. I think it should be titled 'rules code comments' or 'rules developer comments'

OnkelTem’s picture

@timb

Yep, that's to what I've come up too:
1) The module is called now rules_dev_comments
2) Comment Rules Item is renamed to "comment"

See the screenshot of an update product title procedure. (UPDATE: d.org upload is broken. Will retry now)

Latest version is here:
http://drupal.org/sandbox/onkeltem/1719474

OnkelTem’s picture

zhangtaihao’s picture

This almost strikes me as an attempt to reproduce what in Rules 6.x-1.x were the customized element labels. The idea back then was for the administrator to specify meaningful labels for specific elements.

timb’s picture

Yes. I miss those customized element labels and found my way here. I now find myself using rulesets just so i can add titles to small procedures.

timb’s picture

Issue summary: View changes

Updated issue summary.

TR’s picture

Issue summary: View changes
Status: Needs review » Closed (won't fix)

"Needs review" is for patches that need review. This issue is just an announcement - no patch. I guess it's also an implicit request that this sandbox module code be put into core Rules?

Regardless, the sandbox exists, and you can install it if you find this feature useful. If it needs work, you can participate in the issue queue for the sandbox.

The code in the sandbox is very old and hasn't been maintained, so at this point it can't go directly into Rules. Also, D7 is pretty mature and we're not really adding new features anymore. Effort for development of new features should be directed to D8 at this point.

For all these reasons, I'm closing this issues as "won't fix", meaning this isn't going to be put into core Rules.