Rename file list for next run
This commit is contained in:
parent
6dc5cd590d
commit
2cc9078ad9
|
@ -144,6 +144,7 @@ define_vars() { # {{{
|
||||||
|
|
||||||
## Temp file vars {{{
|
## Temp file vars {{{
|
||||||
readonly ldap_user_list_path="/tmp/${PROGNAME}.ldap.user.list"
|
readonly ldap_user_list_path="/tmp/${PROGNAME}.ldap.user.list"
|
||||||
|
readonly ldap_previous_user_list_path="/tmp/.${PROGNAME}.previous.ldap.user.list"
|
||||||
## }}}
|
## }}}
|
||||||
}
|
}
|
||||||
# }}}
|
# }}}
|
||||||
|
@ -316,6 +317,11 @@ main() { # {{{
|
||||||
for all members of ${RED}${ldap_group_cn},${ldap_group_base}${COLOR_DEBUG} LDAP group \
|
for all members of ${RED}${ldap_group_cn},${ldap_group_base}${COLOR_DEBUG} LDAP group \
|
||||||
from ${RED}${ldap_server}${COLOR_DEBUG} LDAP server ."
|
from ${RED}${ldap_server}${COLOR_DEBUG} LDAP server ."
|
||||||
|
|
||||||
|
## Rename user list for next run of the script
|
||||||
|
## AND exit
|
||||||
|
mv --force -- "${ldap_user_list_path}" "${ldap_previous_user_list_path}" \
|
||||||
|
&& exit 0
|
||||||
|
|
||||||
}
|
}
|
||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue