OPTION 2: DELETING SOURCE

This commit is contained in:
qo-op 2020-12-15 23:36:17 +01:00
parent f5005cc0eb
commit bf5451d6e5
1 changed files with 14 additions and 7 deletions

View File

@ -86,16 +86,23 @@ fi
# /_/\_\_.__/|_|\__,_|_| |_|
#
# Transfert ~/astroport/films and animes to IPFS and make Vstream/ASTROPORT indexes on IPNS
# NOT DELETING SOURCE
[[ $(($minute % 30 )) == 0 ]] && $MY_PATH/zen/xbian_vstream.sh &
# restart inotifywait DELETING SOURCE
if [[ "$timebar" == "03:03" ]]; then
# killall inotifywait
# inotifywait -e close_write -m ~/astroport/films | while read dir flags file; do $MY_PATH/zen/xbian_FASTRXBIAN.sh "$file"; done &
# inotifywait -e close_write -m ~/astroport/animes | while read dir flags file; do $MY_PATH/zen/xbian_AASTRXBIAN.sh "$file"; done &
# OPTION 1 : NOT DELETING SOURCE
# NB: Index published in ~/.zen/ipfs/xbian is the same as files in ~/astroport/*/
# [[ $(($minute % 30 )) == 0 ]] && $MY_PATH/zen/xbian_vstream.sh &
# OPTION 2: DELETING SOURCE
# NB: INDEX published in ~/.zen/ipfs/xbian IS ONLY GROWING...
# Must manualy run "ipfs unpin" + "ipfs rm" to clean bad files from ~/.zen/ipfs/xbian/INDEXFILES !!!
if [[ $isinotifywaitRunning == "" ]]; then
inotifywait -e close_write -m ~/astroport/films | while read dir flags file; do $MY_PATH/zen/xbian_FASTRXBIAN.sh "$file"; done &
inotifywait -e close_write -m ~/astroport/animes | while read dir flags file; do $MY_PATH/zen/xbian_AASTRXBIAN.sh "$file"; done &
fi
# restart inotifywait (may be useless)
if [[ "$timebar" == "03:03" ]]; then
killall inotifywait
fi
## TODO investigate could breaks "ipfs p2p" forwards ?
##################################################################