Pārlūkot izejas kodu

Prefer 'editor' on a system that supports alternatives.

Niels Keurentjes 9 gadi atpakaļ
vecāks
revīzija
93ce87a84e
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      src/Composer/Command/ConfigCommand.php

+ 1 - 1
src/Composer/Command/ConfigCommand.php

@@ -188,7 +188,7 @@ EOT
                 if (Platform::isWindows()) {
                 if (Platform::isWindows()) {
                     $editor = 'notepad';
                     $editor = 'notepad';
                 } else {
                 } else {
-                    foreach (array('vim', 'vi', 'nano', 'pico', 'ed') as $candidate) {
+                    foreach (array('editor', 'vim', 'vi', 'nano', 'pico', 'ed') as $candidate) {
                         if (exec('which '.$candidate)) {
                         if (exec('which '.$candidate)) {
                             $editor = $candidate;
                             $editor = $candidate;
                             break;
                             break;