Commit graph

30 commits

Author SHA1 Message Date
Félix Saparelli
7875b4db67
Provide filterer as trait
which will allow basically anything user-provided as filter, though of
course we'll have (soon) our own fairly comprehensive implementation
2021-09-22 23:39:41 +12:00
Félix Saparelli
f1685821a3
Split types out of action 2021-09-18 17:20:05 +12:00
Félix Saparelli
e5fcc6553e
Also leave alt buffer on reset 2021-09-04 02:00:57 +12:00
Félix Saparelli
4043ed34ae
Add Reset outcome (#186, #211) 2021-09-04 01:55:25 +12:00
Félix Saparelli
645ab74c62
Implement Outcome::Wait, and CLI on-busy=queue 2021-09-03 09:25:23 +12:00
Félix Saparelli
b923638cbd
Correctly watch for process completion 2021-09-03 09:25:06 +12:00
Félix Saparelli
ec6b508894
Ignoring supervisor kill/signal internal errors
As the errors only occur when the process is dead anyway
2021-09-03 05:43:26 +12:00
Félix Saparelli
f880b0b38a
Always apply Both outcomes, even when the first fails 2021-09-03 05:41:50 +12:00
Félix Saparelli
8e4994abca
Add process supervisor to watch command to completion
Also change the concept of a completion handler to instead sending a
synthetic "process completed" event down the same path as usual.

That makes handling completion the job of the action handler, but also
means it's immediately possible to launch a process or do an action in
response to the process completing. Win win!
2021-09-03 05:22:15 +12:00
Félix Saparelli
ef453193af
Add pre-spawn and post-spawn hooks 2021-08-25 04:41:14 +12:00
Félix Saparelli
9cb1f5bf79
Re-export Outcome's Signal type 2021-08-24 21:31:46 +12:00
Félix Saparelli
9b94f18890
Fix double-actioning in throttle 2021-08-23 03:12:23 +12:00
Félix Saparelli
60ed6bba25
Fix infinite loop in action recv code 2021-08-23 02:34:29 +12:00
Félix Saparelli
05117e69fe
Prep for more handlers in action 2021-08-23 02:33:23 +12:00
Félix Saparelli
4843920a36
Protect again starting command without anything in command 2021-08-23 02:32:48 +12:00
Félix Saparelli
17b09d8798
Add graceful exit support 2021-08-23 02:32:08 +12:00
Félix Saparelli
3066ee5913
Implement most of process handling 2021-08-23 00:28:20 +12:00
Félix Saparelli
f150c26b22
Add action.grouped config 2021-08-23 00:27:45 +12:00
Félix Saparelli
d2d0bb7be2
Resolve compound outcomes 2021-08-22 23:23:01 +12:00
Félix Saparelli
7a709b9b4d
Prefer generic Both combinator than specific ClearAnd 2021-08-22 23:22:27 +12:00
Félix Saparelli
227c2a0e0d
Add command and shell options to action 2021-08-22 22:06:31 +12:00
Félix Saparelli
8998c40746
Add convenience methods for Outcome's combinators 2021-08-22 22:05:45 +12:00
Félix Saparelli
53854d93d4
Change Outcome::OrStart to the more flexible ::IfRunning 2021-08-22 20:47:47 +12:00
Félix Saparelli
656c0d8fd2
Fix action throttling
Specifically, on loop start the timeout would be for the full throttle duration,
which is not correct if some time has passed or the loop goes on recycle
2021-08-22 20:29:57 +12:00
Félix Saparelli
40f6f7397f
Fill out Outcome 2021-08-22 20:27:51 +12:00
Félix Saparelli
5b8611a8c0
Make notes on needed docs 2021-08-22 20:26:48 +12:00
Félix Saparelli
350b85e0c7
Allow an outcome to be determined by the action handler without &mut! 2021-08-22 18:56:57 +12:00
Félix Saparelli
2a0661b122
Call action handler on action 2021-08-22 05:58:03 +12:00
Félix Saparelli
2812a723ff
Write action throttling code 2021-08-22 02:54:02 +12:00
Félix Saparelli
0f37e42243
Add action worker 2021-08-21 04:43:55 +12:00