Package com.intellij.execution.configurations

Examples of com.intellij.execution.configurations.GeneralCommandLine.createProcess()


    }

    private HaskellConsoleProcessHandler initAndRun(String... statements2execute) throws ExecutionException {
        // Create Server process
        GeneralCommandLine cmdline = createCommandLine(module, workingDir);
        Process process = cmdline.createProcess();
        // !!! do not change order!!!
        consoleView = createConsoleView();
        String commandLine = cmdline.getCommandLineString();
        processHandler = new HaskellConsoleProcessHandler(process, commandLine, getLanguageConsole());
        executeHandler = new HaskellConsoleExecuteActionHandler(processHandler, project, false);
View Full Code Here


      arguments = new String[0];
    }

    final GeneralCommandLine cmdLine = createAndSetupCmdLine(workingDir, command[0], arguments);
    try {
      process = cmdLine.createProcess();
    } catch (Exception e) {
      LOG.error(e.getMessage(), e);
    }
    return process;
  }
View Full Code Here

          commandLine.addParameter(filePath);

          final TextConsoleBuilder consoleBuilder = TextConsoleBuilderFactory.getInstance().createBuilder(module.getProject());
          setConsoleBuilder(consoleBuilder);

          return new OSProcessHandler(commandLine.createProcess(), commandLine.getCommandLineString());
        }
      }, contentToReuse, env);
    }

    if (configuration.isCustomFileToLaunch()) {
View Full Code Here

    final Sdk sdk = ModuleRootManager.getInstance(module).getSdk();
    assert sdk != null;

    GeneralCommandLine commandLine = getCommandForNeko(sdk, settings);

    return new OSProcessHandler(commandLine.createProcess(), commandLine.getCommandLineString());
  }

  private GeneralCommandLine getCommandForNeko(Sdk sdk, HaxeModuleSettings settings) throws ExecutionException {
    final HaxeSdkData sdkData = sdk.getSdkAdditionalData() instanceof HaxeSdkData ? (HaxeSdkData)sdk.getSdkAdditionalData() : null;
    if (sdkData == null) {
View Full Code Here

    final Sdk sdk = ModuleRootManager.getInstance(module).getSdk();
    assert sdk != null;

    GeneralCommandLine commandLine = getCommandForNeko(sdk, settings);

    return new OSProcessHandler(commandLine.createProcess(), commandLine.getCommandLineString());
  }

  private GeneralCommandLine getCommandForNeko(Sdk sdk, HaxeModuleSettings settings) throws ExecutionException {
    final HaxeSdkData sdkData = sdk.getSdkAdditionalData() instanceof HaxeSdkData ? (HaxeSdkData)sdk.getSdkAdditionalData() : null;
    if (sdkData == null) {
View Full Code Here

    assert settings.getHaxeTarget() == HaxeTarget.NEKO;
    final HaxeSdkData sdkData = sdk.getSdkAdditionalData() instanceof HaxeSdkData ? (HaxeSdkData)sdk.getSdkAdditionalData() : null;

    GeneralCommandLine commandLine = getCommandForNeko(sdkData, settings);

    return new OSProcessHandler(commandLine.createProcess(), commandLine.getCommandLineString());
  }

  private GeneralCommandLine getCommandForNeko(@Nullable HaxeSdkData sdkData, HaxeModuleSettings settings) throws ExecutionException {
    if (sdkData == null || sdkData.getNekoBinPath() == null || sdkData.getNekoBinPath().isEmpty()) {
      throw new ExecutionException(HaxeBundle.message("haxe.run.bad.neko.bin.path"));
View Full Code Here

    command.addParameter("-help");
    command.setWorkDirectory(path);

    try {
      final ProcessOutput output = new CapturingProcessHandler(
        command.createProcess(),
        Charset.defaultCharset(),
        command.getCommandLineString()).runProcess();

      if (output.getExitCode() != 0) {
        LOG.error("Haxe compiler exited with invalid exit code: " + output.getExitCode());
View Full Code Here

  @Override
  public void run() {
    final GeneralCommandLine generalCommandLine = new GeneralCommandLine(PhoneGapSettings.IOS_SIM, "--version");
    generalCommandLine.setWorkDirectory(project.getBasePath());
    try {
      generalCommandLine.createProcess();
    } catch (Exception e) {
      /* ios-sim not run */
      String groupeDisplayId = "PhoneGap notification";
      String notificationTitle = "PhoneGap Plugin";
      String notificationMessage = "ios-sim not detected";
View Full Code Here

        generalCommandLine.setWorkDirectory(myProject.getBasePath());
        try {
            final OSProcessHandler handler = new OSProcessHandler(generalCommandLine);
            //handler.addProcessListener(this);
            handler.startNotify();
            generalCommandLine.createProcess();
        } catch (Exception e) {
            noPhoneGap();

        }
    }
View Full Code Here

  private ProcessOutput executeAndGetOut(String[] command) throws ExecutionException {
    final GeneralCommandLine commandLine = new GeneralCommandLine(command);
    commandLine.withWorkDirectory(myWorkDir);
    commandLine.setPassParentEnvironment(true);
    Process process = commandLine.createProcess();
    OSProcessHandler processHandler = new ColoredProcessHandler(process, commandLine.getCommandLineString(), Charsets.UTF_8);
    final ProcessOutput output = new ProcessOutput();
    processHandler.addProcessListener(new ProcessAdapter() {
      @Override
      public void onTextAvailable(ProcessEvent event, Key outputType) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.