File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed
src/org/netbeans/modules/php/wordpress Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change 81
81
*/
82
82
public final class WordPressCli {
83
83
84
- public static String NAME = "wp" ; // NOI18N
85
- public static String LONG_NAME = "wp-cli.phar" ; // NOI18N
84
+ public static final String NAME = "wp" ; // NOI18N
85
+ public static final String LONG_NAME = "wp-cli.phar" ; // NOI18N
86
+ public static final String NAME_BAT = "wp.bat" ; // NOI18N
86
87
87
88
private final String wpCliPath ;
88
89
private boolean noReset = false ;
Original file line number Diff line number Diff line change 55
55
import javax .swing .event .DocumentEvent ;
56
56
import javax .swing .event .DocumentListener ;
57
57
import org .netbeans .api .progress .ProgressHandle ;
58
- import org .netbeans .api .progress .ProgressHandleFactory ;
59
58
import org .netbeans .modules .php .api .executable .InvalidPhpExecutableException ;
60
59
import org .netbeans .modules .php .api .util .FileUtils ;
61
60
import org .netbeans .modules .php .api .util .StringUtils ;
69
68
import org .openide .util .Exceptions ;
70
69
import org .openide .util .NbBundle ;
71
70
import org .openide .util .RequestProcessor ;
71
+ import org .openide .util .Utilities ;
72
72
73
73
final class WordPressOptionsPanel extends javax .swing .JPanel {
74
74
@@ -537,6 +537,9 @@ private void wpCliSearchButtonActionPerformed(java.awt.event.ActionEvent evt) {/
537
537
String script = UiUtils .SearchWindow .search (new UiUtils .SearchWindow .SearchWindowSupport () {
538
538
@ Override
539
539
public List <String > detect () {
540
+ if (Utilities .isWindows ()) {
541
+ return FileUtils .findFileOnUsersPath (WordPressCli .NAME , WordPressCli .LONG_NAME , WordPressCli .NAME_BAT );
542
+ }
540
543
return FileUtils .findFileOnUsersPath (WordPressCli .NAME , WordPressCli .LONG_NAME );
541
544
}
542
545
You can’t perform that action at this time.
0 commit comments