Commit graph

14208 commits

Author SHA1 Message Date
Joey Hess
88ec6eff15 add/remove/edit schedule UI working
Once I built the basic widget, it turned out to be rather easy to replicate
it once per scheduled activity and wire it all up to a fully working UI.

This does abuse yesod's form handling a bit, but I think it's ok.
And it would be nice to have it all ajax-y, so that saving one modified
form won't lose any modifications to other forms. But for now, a nice
simple 115 line of code implementation is a win.

This late night hack session commit was sponsored by Andrea Rota.
2013-10-11 03:04:11 -04:00
Joey Hess
aa5b2f1c3c basic fsck form UI 2013-10-11 00:46:04 -04:00
Joey Hess
e36da0e5ad better time display 2013-10-11 00:29:28 -04:00
Joey Hess
e9745f2da2 add config page for fsck, and alert with button when a fsck is running 2013-10-10 18:05:53 -04:00
Joey Hess
18f4d1b400 queue downloads of keys that fsck finds with bad content 2013-10-10 17:27:00 -04:00
Joey Hess
82083658cf stop fsck when scheduled activity is removed 2013-10-10 16:22:55 -04:00
Joey Hess
ebcbea4576 unmask async exceptions after fork
Turns out that forkProcess masks async exceptions. Unmask them so that the
daemon code can use them for thread IPC.

There is some risk this introduces breakage in git-annex, but it would be
breakage that would already occur when the assistant was run with
--foreground.
2013-10-10 16:05:44 -04:00
Joey Hess
7abe6cb161 0 pad minutes 2013-10-10 14:12:24 -04:00
Joey Hess
6a331d1261 got delay calculation backwards 2013-10-10 12:55:30 -04:00
Joey Hess
5b70eac659 fix option name 2013-10-10 12:49:54 -04:00
Joey Hess
c80bc53960 cronner builds, should work (untested)
I probably need to improve handling of the PleaseTerminate exception to
kill the fsck process. Also, if fsck finds bad files, something needs
to requeue downloads of them. Otherwise, this should work, but is probably
quite buggy since I have only tested the pure code over the past 2 days.
2013-10-08 18:13:08 -04:00
Joey Hess
3621044203 remove duration from Schedule 2013-10-08 17:44:20 -04:00
Joey Hess
2b6747b6a2 update for Duration type change 2013-10-08 17:36:55 -04:00
Joey Hess
51c44b26aa quickcheck duration 2013-10-08 17:35:25 -04:00
Joey Hess
ca83b16415 expand with a fromDuration and support for mixed unit durations 2013-10-08 17:12:38 -04:00
Joey Hess
af5e1d0494 half way complete cronner thread to run scheduled activities 2013-10-08 11:48:28 -04:00
Joey Hess
36ddd000ea qualify import; also available in crypto-random 2013-10-08 11:14:25 -04:00
Joey Hess
fe3a038e91 refactor 2013-10-07 23:58:26 -04:00
Joey Hess
f409223d53 comment typo 2013-10-07 23:48:29 -04:00
Joey Hess
1d5207b1e5 calculating the next time on a Schedule
Wow! This was hairy, but about 10x less hairy than expected actually!
A bit more recursion than I really like, since I think in theory all
of this date stuff can be calulated using some formulas I am too lazy too
look up. But this doesn't matter in practice; I asked it for
nextTime (Schedule (Divisible 100 (Yearly 7)) (SpecificTime 23 59) (MinutesDuration 10)) Nothing
.. and it calculated (NextTimeExactly 2100-01-07 23:59:00) in milliseconds.
2013-10-07 23:13:30 -04:00
Joey Hess
cf6403a13c better recurrance formatting 2013-10-07 18:07:31 -04:00
Joey Hess
b9375acb18 add schedule to vicfg 2013-10-07 17:11:13 -04:00
Joey Hess
c840d54fab quickcheck schedule parsing
soo many arbitrary instances, so little time!
2013-10-07 17:05:30 -04:00
Joey Hess
29ca49dad4 add a log file for scheduled activities 2013-10-07 16:06:34 -04:00
Joey Hess
b22ed77fc4 basic data types for scheduled activities
Rather similar to crontab, although with a different format.
But with less emphasis on per-minute scheduling.
Also, supports weekly events, which cron makes too hard.
Also, has a duration field.
2013-10-07 15:36:42 -04:00
Joey Hess
86901393fc Merge branch 'master' of ssh://git-annex.branchable.com 2013-10-07 13:12:05 -04:00
http://joeyh.name/
01b2724e51 Added a comment: How can I resolve a non-fast-forware on the git-annex branch? 2013-10-07 17:08:34 +00:00
Joey Hess
45aed381df import: Skip .git directories. 2013-10-07 13:03:05 -04:00
Joey Hess
ac26b70809 Merge branch 'master' of ssh://git-annex.branchable.com 2013-10-07 12:49:11 -04:00
https://www.google.com/accounts/o8/id?id=AItOawnpdM9F8VbtQ_H5PaPMpGSxPe_d5L1eJ6w
fa969371a3 Added a comment 2013-10-07 13:33:41 +00:00
https://id.koumbit.net/anarcat
419925d285 warn about fellow destruction 2013-10-07 12:18:10 +00:00
https://id.koumbit.net/anarcat
75fd6e87bd sign 2013-10-07 12:07:07 +00:00
https://id.koumbit.net/anarcat
a9fab4d7b9 Added a comment: it's worse than not working, it kills! :) 2013-10-07 12:06:22 +00:00
https://id.koumbit.net/anarcat
19763df501 import not only doesn't work, it kills 2013-10-07 12:02:56 +00:00
https://www.google.com/accounts/o8/id?id=AItOawm5iosFbL2By7UFeViqkc6v-hoAtqILeDA
0b5c2609ad Added a comment 2013-10-07 09:17:31 +00:00
Joey Hess
6622875cf8 Revert "use vector in local status", which was not an improvement
This reverts commit eb3ce3581a.
2013-10-07 04:06:10 -04:00
Joey Hess
eb3ce3581a use vector in local status
Thought was that this would be faster than a map, since a vector can be
updated more efficiently. It turns out to not seem to matter; runtime and
memory usage are basically identical.
2013-10-07 04:05:14 -04:00
Joey Hess
1200788859 status: Fix space leak in local mode, introduced in version 4.20130920.
Actually fixed 2 leaks, the tuple leak may have been older.
2013-10-07 03:59:14 -04:00
https://www.google.com/accounts/o8/id?id=AItOawkC0W3ZQERUaTkHoks6k68Tsp1tz510nGo
66935a8188 Added a comment: sync, push, pull with/to/from centralized bare repository 2013-10-07 06:45:24 +00:00
Joey Hess
5acb47fb7c Merge branch 'master' of ssh://git-annex.branchable.com 2013-10-06 21:15:22 -04:00
Joey Hess
267c124f67 run ssh in the directory with its socket when stopping
This guarantees that stopping an existing socket never fails.

This might be the route out of the mess of needing to worry about socket
lengths in general. However, it would need quite a lot of refactoring
to make every place in git-annex that runs ssh run it with a cwd that was
determined by the location of its connection caching socket. If this
wasn't already such a mess, I'd consider even the thought of that API a bad
idea..
2013-10-06 21:11:39 -04:00
Joey Hess
6f38426cb8 work around ssh brain-damange
The control socket path passed to ssh needs to be 17 characters shorter
than the maximum unix domain socket length, because ssh appends stuff to it
to make a temporary filename. Closes: #725512

Also, take the shorter of the relative and the absolute paths to the
socket. Typically the relative path will be a lot shorter (unless
deep inside a subdirectory of the repository), and so using it will
avoid flirting with the maximum safe socket lenghts in more situations,
and so lead to less breakage if all my attempts at fixing this are
still buggy.
2013-10-06 20:59:36 -04:00
https://www.google.com/accounts/o8/id?id=AItOawnZEanlyzay_QlEAL0CWpyZcRTyN7vay8U
8a19b0e50b Added a comment: Tilde did it for me 2013-10-06 21:59:44 +00:00
Joey Hess
990924703f factor out Build.Version 2013-10-06 17:48:38 -04:00
Joey Hess
319d194040 GHCMAKE not used 2013-10-06 17:34:10 -04:00
Joey Hess
571fe4999b remove __WINDOWS__ ifdef 2013-10-06 17:23:30 -04:00
https://www.google.com/accounts/o8/id?id=AItOawlOc-EOD5ZyggsAp6lOnU7x5MxizwLtUXA
897bc8f845 Added a comment 2013-10-06 18:35:14 +00:00
https://id.koumbit.net/anarcat
ecd26dbe52 fix typo 2013-10-06 17:15:16 +00:00
http://joeyh.name/
b07b7f9b9e Added a comment: thanks for your checking.. 2013-10-06 17:04:24 +00:00
Joey Hess
39369365ec set preferred content expression 2013-10-06 13:03:02 -04:00