-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcrontab.fastest
69 lines (64 loc) · 7.06 KB
/
crontab.fastest
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Your email address here if you want to keep track of what's happening.
MAILTO=""
# This form ensures that cron jobs only send emails when your command exits with an error.
# Successful jobs are silent.
# OUTPUT=`... your command here ...` 2>&1 || echo "$OUTPUT"
# The cron jobs in this example are designed to maximize your use of the rate-limited
# Foursquare API. They run the sync script every 64 minutes = 45 jobs over 48 hours.
# There's probably a better way to do this :)
# A simpler cron would just run hourly or daily. For example:
# 0 * * * * OUTPUT=`~/Congregate/pull-and-build.sh 2>&1` || echo "$OUTPUT"
# Much simpler than the below. Only one job, and no funky calls to `test`.
# Hourly or daily should be plenty for most people after the initial sync is complete.
# (Daily for the initial sync works, but is slow. Hourly for the initial sync works
# but, because of some timing issues, is probably equivalent to running the sync
# every two hours, which is ~twice as slow as the example below.)
# Run on even days
0 0 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
# Full sync once a day
4 1 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh 2>&1` || echo "$OUTPUT" )
8 2 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
12 3 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
16 4 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
20 5 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
24 6 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
28 7 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
32 8 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
36 9 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
40 10 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
44 11 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
48 12 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
52 13 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
56 14 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
0 16 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
4 17 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
8 18 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
12 19 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
16 20 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
20 21 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
24 22 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
28 23 * * * test $(( $( date +\%-j ) \% 2 )) -eq 0 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
# Run on odd days
32 0 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
# Full sync once a day
36 1 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh 2>&1` || echo "$OUTPUT" )
40 2 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
44 3 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
48 4 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
52 5 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
56 6 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
0 8 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
4 9 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
8 10 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
12 11 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
16 12 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
20 13 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
24 14 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
28 15 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
32 16 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
36 17 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
40 18 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
44 19 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
48 20 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
52 21 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )
56 22 * * * test $(( $( date +\%-j ) \% 2 )) -eq 1 && ( OUTPUT=`~/Congregate/pull-and-build.sh --type=checkins 2>&1` || echo "$OUTPUT" )