Skip to content

Commit afd90c1

Browse files
committed
Update openthos
Update openthos
1 parent b7ddc76 commit afd90c1

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

deployer/script/openthos.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,13 @@ warn() {
1616
echo "$1"
1717
}
1818

19+
cd /data/mirrors/openthos
1920
latest=`curl -s -v -X HEAD $HOST 2>&1 | grep 'Last-Modified:' | cut -d ':' -f2 | awk '{gsub(/^ +| +$/,"")}1'`
2021
last_modified=`cat $timestamp`
2122

22-
if [ $latest != $last_modified ]; then
23+
if [ "$latest" != "$last_modified" ]; then
2324
curl $HOST -LO
24-
latest > $timestamp
25+
echo "$latest" > $timestamp
2526
fi
2627

2728
rm -f $lock

deployer/script/state.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ def getState():
2121

2222
last_modify = {
2323
'centos': '/timestamp.txt',
24+
'openthos': '/timestamp.txt',
2425
'android': '/repository',
2526
'epel': '/fullfilelist',
2627
'pypi': '/status'

0 commit comments

Comments
 (0)