manage cloud links
This commit is contained in:
@ -136,6 +136,10 @@ LOG " - ${BLUE}mbox: ${mbox}${NC}${YELLOW}"
|
||||
"${eMailShrinker}" -l "${mbox}"
|
||||
LOG "${NC}"
|
||||
|
||||
########################################
|
||||
# Préparation pour le cloud
|
||||
rm -f "${TMP_DIR}/last.txt"
|
||||
|
||||
########################################
|
||||
# recherche des prolongations des délais de grace
|
||||
"${eMailShrinker}" ${DEBUG} -u "${mbox}" > "${TMP_DIR}/url-to-refresh.txt"
|
||||
@ -145,6 +149,7 @@ cat "${TMP_DIR}/url-to-refresh.txt" | grep "${JIRAFEAU_URL}" | while read REMOTE
|
||||
LOG " - ${BLUE}update ${REMOTE_REF}${NC}"
|
||||
curlJirafeauUpdate "${PERIODE}" "${REMOTE_REF}"
|
||||
echo "old: ${REMOTE_REF} ${REMOTE_KEY}" >> "${TMP_DIR}/archive-content.txt"
|
||||
echo "f=${REMOTE_REF}~${REMOTE_KEY}" > "${TMP_DIR}/last.txt"
|
||||
done
|
||||
|
||||
########################################
|
||||
@ -188,6 +193,7 @@ cat "${TMP_DIR}/PJ-name.txt" | {
|
||||
LOG " - ${GREEN} upload ${ATTACH_MEDIA}${NC}"
|
||||
echo "url: ${JIRAFEAU_URL}/f.php?d=1&h=${JIR_TOKEN}&k=${PASSWORD_MD5}"
|
||||
echo "new: ${JIR_TOKEN} ${PASSWORD_MD5}" >> "${TMP_DIR}/archive-content.txt"
|
||||
echo "f=${JIR_TOKEN}~${PASSWORD_MD5}" > "${TMP_DIR}/last.txt"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
@ -209,6 +215,7 @@ cat "${TMP_DIR}/PJ-name.txt" | {
|
||||
* )
|
||||
LOG " - ${GREEN} upload archive-content.txt${NC}"
|
||||
echo "arch: ${JIRAFEAU_URL}/a.php?g=${JIR_TOKEN}~${PASSWORD_MD5}"
|
||||
echo "a=${JIR_TOKEN}~${PASSWORD_MD5}" > "${TMP_DIR}/last.txt"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
@ -216,6 +223,12 @@ cat "${TMP_DIR}/PJ-name.txt" | {
|
||||
LOG " - ${GREEN}no archive${NC}"
|
||||
echo "arch: none"
|
||||
fi
|
||||
if [ -s "${TMP_DIR}/last.txt" ]; then
|
||||
echo "cloud: ${JIRAFEAU_URL}/c.php?$(cat "${TMP_DIR}/last.txt")"
|
||||
else
|
||||
echo "cloud: none"
|
||||
fi
|
||||
|
||||
} > "${TMP_DIR}/PJ-Keys.txt"
|
||||
|
||||
LOG " - ${BLUE}PJ-Keys: ${NC}"
|
||||
|
Reference in New Issue
Block a user