示例#1
0
 public static ITascTarget Exec(this ITascTarget target, string command, params string[] cmdParams)
 {
     return(target.Do(new ExecTasc(command, cmdParams)
     {
         RunWindowed = false
     }));
 }
示例#2
0
 public static ITascTarget Tasc(this ITascTarget target, Action <TascContext> action)
 {
     return(target.Do(new GenericTasc(context =>
     {
         try
         {
             action(context);
         }
         catch (TascException)
         {
             return TascResult.Fail;
         }
         return TascResult.Pass;
     })));
 }
示例#3
0
 public static ITascTarget Echo(this ITascTarget target, string line)
 {
     return(target.Do(new EchoTasc(line)));
 }
示例#4
0
 public static ITascTarget Tasc(this ITascTarget target, Func <TascContext, ITascResult> action)
 {
     return(target.Do(new GenericTasc(action)));
 }