Comment: | Added a simple crontab-like function for time based triggers |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | run-mgr |
Files: | files | file ages | folders |
SHA1: |
27f026b7305a682fa3b0e64f14dc7e53 |
User & Date: | matt on 2017-02-18 22:15:23 |
Other Links: | branch diff | manifest | tags |
2017-02-18
| ||
22:40 | Added basic crontab based launching check-in: 5d3a3776be user: matt tags: run-mgr | |
22:15 | Added a simple crontab-like function for time based triggers check-in: 27f026b730 user: matt tags: run-mgr | |
2017-02-16
| ||
22:06 | Fixed launching of viewscreen causing hesitation on cleanrunexecute check-in: d2a7fb2fe4 user: matt tags: run-mgr | |
Modified common.scm from [e8e9c53bae] to [0892af02f7].
1686 1687 1688 1689 1690 1691 1692 | 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 | - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + | '( y mo w d h m s)))) (list 8 6 5 2 1))) '(5 10 15 20 30 40 50 500)) (if values (apply values result) (values 0 day 1 0 'd)))) |
Modified mtut.scm from [a17ee21a60] to [28506ee857].
242 243 244 245 246 247 248 | 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 | - - + + | (if (not exists) (let* ((pktdat (string-intersperse (with-input-from-file pkt read-lines) "\n")) (apkt (convert-pkt->alist pktdat)) (ptype (alist-ref 'T apkt))) (add-to-queue pdb pktdat uuid (or ptype 'cmd) #f 0) |
Added tests/unittests/cron.scm version [700c4402ed].
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | + + + + + + + + + + + + + + + + + + + | (use test) ;; S M H MD MTH YR WD (define ref-time (vector 58 39 21 18 1 117 6 48 #f 25200)) (for-each (lambda (situation crontab ref-seconds last-done expected) (print "\nsituation: " situation) (print "ref-seconds: " ref-seconds " = " (time->string (seconds->local-time ref-seconds))) (print "last-done: " last-done " = " (time->string (seconds->local-time last-done))) (print "crontab: " crontab) (test #f expected (common:cron-event crontab ref-seconds last-done))) '("midnight" "midnight, already done" "diffdate" "diffdate, already done" "diffday" "sameday, already done") '("0 0 * * *" "0 0 * * *" "0 0 18 * *" "0 0 18 * *" "0 0 * * 5" "0 0 18 * 6" ) '(1487489998.0 1487489998.0 1487489998.0 1487489998.0 1487489998.0 1487489998.0 ) '(1487479198.0 1487489098.0 1487479198.0 1487489098.0 1487479198.0 1487489098.0 ) '( #t #f #f #f #f #f ) ) |