-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathUnitBuild.java
More file actions
37 lines (30 loc) · 779 Bytes
/
UnitBuild.java
File metadata and controls
37 lines (30 loc) · 779 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
package ccg.cmmdLine;
import java.util.Scanner;
import java.util.regex.Pattern;
import javax.swing.JOptionPane;
public class UnitBuild implements Runnable
{
private Scanner sc = new Scanner(System.in);
public static void main(String[] args)
{
try
{
UnitBuild un = new UnitBuild();
un.run();
}
catch(Exception e)
{
JOptionPane.showMessageDialog(null, "Could not run or start the environment for: CCG");
}
}
public void run()
{
CmmdEnvironment cmdline = new CmmdEnvironment();
System.out.println("(C) 2016 class code generator - command line started\n\nPress 'help' or '/?' for help");
String input = sc.next();
if(Pattern.matches("[hH][eE][lL][pP]", input) || input.equals("/?"))
{
System.out.println(cmdline.help());
}
}
}