Page MenuHomePhabricator

How do I get a non-block-based custom remarkup rule to work fine in phabricator?
Closed, ResolvedPublic

Asked by yelirekim on Mar 30 2016, 8:10 PM.

Details

Am I doing something insanely stupid? I can't seem to get this to actually produce log output when I keyboard mash wantonly into maniphest task descriptions with this extension loaded underneath. Yes, I am highly confident my logging function works.

<?php

final class PhutilProcessLogPathRule extends PhutilRemarkupRule {

  public function apply($text) {

    integrator_debug_log('processlogtest.log', 'omgplswork');

    return $text;
  }

}

Answers

epriestley
Updated 2,954 Days Ago

Subclasses of PhutilRemarkupRule are not automatically picked up. Possibly they should be since this is a bit inconsistent, but there are okay-ish-reasons for them to work a little differently.

Extend PhabricatorRemarkupCustomInlineRule instead for automatic pickup, or make an application return the rule from getRemarkupRules() to activate it whenever that application is installed.

New Answer

Answer

This question has been marked as closed, but you can still leave a new answer.