move function, add timestamp on initial clone
This commit is contained in:
parent
0925848e5f
commit
9233124e69
3 changed files with 13 additions and 6 deletions
10
bashrc_add
10
bashrc_add
|
@ -103,6 +103,16 @@ EOF
|
|||
|
||||
}
|
||||
|
||||
lastupdatesubmodules () {
|
||||
date "+%s" > ${MSC_BASE%/}${MSC_BASE:+/}.last_update_submodules
|
||||
}
|
||||
export -f lastupdatesubmodules
|
||||
|
||||
lastupdaterepo () {
|
||||
date "+%s" > ${MSC_BASE%/}${MSC_BASE:+/}.last_update_repo
|
||||
}
|
||||
export -f lastupdaterepo
|
||||
|
||||
sync_config () {
|
||||
if $MSC_GIT_SYNC; then
|
||||
local nok=""
|
||||
|
|
|
@ -20,12 +20,7 @@
|
|||
[ -z "${MSC_GIT_REMOTE_NAME+x}" ] && export MSC_GIT_REMOTE_NAME=origin
|
||||
[ -z "${MSC_GIT_BRANCH+x}" ] && export MSC_GIT_BRANCH=master
|
||||
|
||||
lastupdatesubmodules () {
|
||||
date "+%s" > ${MSC_BASE%/}${MSC_BASE:+/}.last_update_submodules
|
||||
}
|
||||
lastupdaterepo () {
|
||||
date "+%s" > ${MSC_BASE%/}${MSC_BASE:+/}.last_update_repo
|
||||
}
|
||||
|
||||
|
||||
gitupdateend() {
|
||||
cat << EOF >> "${MSC_LOGFILE}"
|
||||
|
|
|
@ -334,6 +334,8 @@ sshmyshellconfig() {
|
|||
rm -rf ~/server-config && echo rm -rf ~/server-config
|
||||
loginfo git clone
|
||||
git clone --recurse-submodules $MSC_GIT_REMOTE \${HOME}/${MSC_SUBPATH}
|
||||
date "+%s" > ${MSC_BASE%/}${MSC_BASE:+/}.last_update_submodules
|
||||
date "+%s" > ${MSC_BASE%/}${MSC_BASE:+/}.last_update_repo
|
||||
|
||||
EOF
|
||||
EXIT
|
||||
|
|
Loading…
Reference in a new issue