]> git.mxchange.org Git - friendica.git/commitdiff
Improve console/config display
authorHypolite Petovan <mrpetovan@gmail.com>
Thu, 12 Jul 2018 03:00:44 +0000 (23:00 -0400)
committerHypolite Petovan <mrpetovan@gmail.com>
Mon, 16 Jul 2018 23:38:18 +0000 (19:38 -0400)
- Add visual distinction between get/set value

src/Core/Console/Config.php

index f619afade06423a4f498e3bc730bddb97be27498..860c9e891d5c830bd95f7aa20c7c223f7cd7ac7e 100644 (file)
@@ -99,7 +99,7 @@ HELP;
                if (count($this->args) == 3) {
                        $result = Core\Config::set($this->getArgument(0), $this->getArgument(1), $this->getArgument(2));
                        if ($result) {
-                               $this->out("{$this->getArgument(0)}.{$this->getArgument(1)} = " .
+                               $this->out("{$this->getArgument(0)}.{$this->getArgument(1)} <= " .
                                        Core\Config::get($this->getArgument(0), $this->getArgument(1)));
                        } else {
                                $this->out("Unable to set {$this->getArgument(0)}.{$this->getArgument(1)}");
@@ -107,7 +107,7 @@ HELP;
                }
 
                if (count($this->args) == 2) {
-                       $this->out("{$this->getArgument(0)}.{$this->getArgument(1)} = " .
+                       $this->out("{$this->getArgument(0)}.{$this->getArgument(1)} => " .
                                Core\Config::get($this->getArgument(0), $this->getArgument(1)));
                }
 
@@ -116,7 +116,7 @@ HELP;
 
                        if (!is_null($a->config[$this->getArgument(0)])) {
                                foreach ($a->config[$this->getArgument(0)] as $k => $x) {
-                                       $this->out("{$this->getArgument(0)}.{$k} = " . $x);
+                                       $this->out("{$this->getArgument(0)}.{$k} => " . $x);
                                }
                        } else {
                                $this->out('Config section ' . $this->getArgument(0) . ' returned nothing');
@@ -135,14 +135,14 @@ HELP;
                                        foreach ($section as $key => $value) {
                                                if (is_array($value)) {
                                                        foreach ($value as $k => $v) {
-                                                               $this->out("{$cat}.{$key}[{$k}] = " . $v);
+                                                               $this->out("{$cat}.{$key}[{$k}] => " . $v);
                                                        }
                                                } else {
-                                                       $this->out("{$cat}.{$key} = " . $value);
+                                                       $this->out("{$cat}.{$key} => " . $value);
                                                }
                                        }
                                } else {
-                                       $this->out("config.{$cat} = " . $section);
+                                       $this->out("config.{$cat} => " . $section);
                                }
                        }
                }