Examples of withWorkDirectory()


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

    }
  }

  private OSProcessHandler serve(String extraArg) throws ExecutionException {
    GeneralCommandLine commandLine = new GeneralCommandLine(concat(newArrayList(myPath, "serve"), parseArgs(extraArg)));
    commandLine.withWorkDirectory(myWorkDir);
    return KillableColoredProcessHandler.create(commandLine);
  }

  @NotNull
  public OSProcessHandler runCommand(@NotNull String command,
View Full Code Here

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

    }
  }

  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() {
View Full Code Here

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

    return createProcessHandler(ArrayUtil.toStringArray(commands));
  }

  private OSProcessHandler createProcessHandler(String... commands) throws ExecutionException {
    GeneralCommandLine commandLine = new GeneralCommandLine(commands);
    commandLine.withWorkDirectory(myWorkDir);
    return KillableColoredProcessHandler.create(commandLine);
  }

  private static List<String> parseArgs(String paramList) {
    ArrayList<String> list = newArrayList();
View Full Code Here

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

        try {
            GeneralCommandLine command = new GeneralCommandLine();
            command.setExePath(goCommand);
            command.addParameter("version");
            command.withWorkDirectory(path);
            command.getEnvironment().put("GOROOT", path);

            ProcessOutput output = new CapturingProcessHandler(
                    command.createProcess(),
                    Charset.defaultCharset(),
View Full Code Here

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

        try {
            GeneralCommandLine command = new GeneralCommandLine();
            command.setExePath(goCommand);
            command.addParameter("env");
            command.withWorkDirectory(path);
            command.getEnvironment().put("GOROOT", path);

            ProcessOutput output = new CapturingProcessHandler(
                    command.createProcess(),
                    Charset.defaultCharset(),
View Full Code Here

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

                return null;
            }
        }

        command.setExePath(execName);
        command.withWorkDirectory(homePath);
        command.addParameter("env");

        sdkData.TARGET_ARCH = GoTargetArch._amd64;
        sdkData.TARGET_OS = GoTargetOs.Linux;
View Full Code Here

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

            if (m_configuration.scriptArguments != null && m_configuration.scriptArguments.trim().length() > 0) {
                commandLine.getParametersList().addParametersString(m_configuration.scriptArguments);
            }

            commandLine.getEnvironment().putAll(sysEnv);
            commandLine.withWorkDirectory(m_configuration.workingDir);

            return GoApplicationProcessHandler.runCommandLine(commandLine);
        }

        // Build and run
View Full Code Here

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

        // Now run the build
        GeneralCommandLine commandLine = new GeneralCommandLine();

        commandLine.setExePath(execName);
        commandLine.withWorkDirectory(m_configuration.workingDir);
        if (m_configuration.scriptArguments != null && m_configuration.scriptArguments.trim().length() > 0) {
            commandLine.getParametersList().addParametersString(m_configuration.scriptArguments);
        }

        return GoApplicationProcessHandler.runCommandLine(commandLine);
View Full Code Here

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

        } else if (testConfiguration.testTargetType.equals(GoTestConfiguration.TestTargetType.CWD)) {
            testInstallDependencies.addParameter("./...");
        }

        testInstallDependencies.getEnvironment().putAll(sysEnv);
        testInstallDependencies.withWorkDirectory(workingDir);
        try {
            if (testInstallDependencies.createProcess().waitFor() == 0) {
                VirtualFileManager.getInstance().syncRefresh();
            }
        } catch (InterruptedException ignored) {
View Full Code Here

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

        } else if (testConfiguration.testTargetType.equals(GoTestConfiguration.TestTargetType.CWD)) {
            commandLine.addParameter("./...");
        }

        commandLine.getEnvironment().putAll(sysEnv);
        commandLine.withWorkDirectory(workingDir);

        if (testConfiguration.testArgs != null && testConfiguration.testArgs.trim().length() > 0) {
            commandLine.getParametersList().addParametersString(testConfiguration.testArgs);
        }
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.