%}
%token TPERMIT TDENY TAS TCMD TARGS
-%token TNOPASS TKEEPENV TSETENV
+%token TNOPASS TPERSIST TKEEPENV TSETENV
%token TSTRING
%%
} | options option {
$$.options = $1.options | $2.options;
$$.envlist = $1.envlist;
+ if (($$.options & (NOPASS|PERSIST)) == (NOPASS|PERSIST)) {
+ yyerror("can't combine nopass and persist");
+ YYERROR;
+ }
if ($2.envlist) {
if ($$.envlist) {
yyerror("can't have two setenv sections");
option: TNOPASS {
$$.options = NOPASS;
$$.envlist = NULL;
+ } | TPERSIST {
+ $$.options = PERSIST;
+ $$.envlist = NULL;
} | TKEEPENV {
$$.options = KEEPENV;
$$.envlist = NULL;
{ "cmd", TCMD },
{ "args", TARGS },
{ "nopass", TNOPASS },
+ { "persist", TPERSIST },
{ "keepenv", TKEEPENV },
{ "setenv", TSETENV },
};