Java Shell Command runShellCommand(String command)

Here you can find the source of runShellCommand(String command)

Description

run Shell Command

License

Open Source License

Declaration

public static void runShellCommand(String command) throws IOException,
            InterruptedException 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.io.IOException;

public class Main {
    public static void runShellCommand(String command) throws IOException,
            InterruptedException {

        System.out.println("execute: " + command);
        Process process = Runtime.getRuntime().exec(command);
        process.waitFor();/* w ww  . j  av  a2s  .  c o  m*/
    }
}

Related

  1. runCommandWithOutput(String cmd)
  2. runShell(File workspace, String... shellElements)
  3. runShell(String cmd)
  4. runShell(String shStr)
  5. runShellCommand(String command)
  6. runShellCommand(String command)
  7. runShellCommand(String[] cmd, StringBuilder outputLines, StringBuilder errorLines)
  8. sendCommand(String path, String cmd)