Skip to content

Instantly share code, notes, and snippets.

View heke2929's full-sized avatar
💭
I may be slow to respond.

heke2929

💭
I may be slow to respond.
View GitHub Profile
@heke2929
heke2929 / wbond-package-control-issues-1057.sh
Created November 10, 2016 06:14 — forked from stanwu/wbond-package-control-issues-1057.sh
Auto Mirror channel_v3.json (Wbond Package-Control Issues #1057)
#!/bin/bash
byte=`curl -s https://packagecontrol.io/channel_v3.json | wc -c`
if [ $byte -gt 2000000 ]; then
echo "OK! mirror it"
cp channel_v3.json channel_v3.json-old
curl -s https://packagecontrol.io/channel_v3.json -o channel_v3.json
cmp -s channel_v3.json channel_v3.json-old
if [ $? == 0 ]; then
echo "We don't need update now"