#! /usr/bin/env python
# -*- coding: utf-8 -*-

prognames = ['skytest', 'gausstest']

import os
import sys
import subprocess
import platform

try:
    # create build dir
    if not os.path.isdir('build'):
        os.mkdir('build')
    os.chdir('build')
    # cmake
    if 'Windows' in platform.uname():
        subprocess.call('cmake -G "Visual Studio 14 Win64" ..', shell=True)
    else:
        subprocess.call('cmake ..', shell=True)
    subprocess.call('cmake --build . --config Release', shell=True)
    if 'Windows' in platform.uname():
        os.chdir('bin/Release')
    # run progs
    for p in prognames:
        subprocess.check_call(os.path.join('.', p), shell=True)
        print "<press ENTER to continue>"
        raw_input()
except Exception as e:
    print e
    print "<press ENTER to quit>"
    raw_input()

@@ -58,20 +58,20 @@
  = %5B'sky
-test
+_app
 ', 'gaus
@@ -75,12 +75,12 @@
 auss
-test
+_app
 '%5D%0A%0A
@@ -324,58 +324,36 @@
 all(
+%5B
 'cmake
- -G %22Visual Studio 14 Win64%22 ..', shell=True
+', '-A', 'x64', '..'%5D
 )%0A  
@@ -388,30 +388,23 @@
 all(
+%5B
 'cmake
- ..', shell=True
+', '..'%5D
 )%0A  
@@ -425,33 +425,43 @@
 all(
+%5B
 'cmake
- 
+', '
 --build
- . 
+', '.', '
 --config
  Rel
@@ -460,17 +460,20 @@
 nfig
- 
+', '
 Release'
 , sh
@@ -468,28 +468,17 @@
 Release'
-, shell=True
+%5D
 )%0A    if

remove shell=True