Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a way to control how ofter restarts occur? #76

Open
and-semakin opened this issue Sep 18, 2019 · 2 comments
Open

Is there a way to control how ofter restarts occur? #76

and-semakin opened this issue Sep 18, 2019 · 2 comments

Comments

@and-semakin
Copy link

and-semakin commented Sep 18, 2019

For example, I have a file that changes very often (IDE periodically saves source code to disk), but I don't want to restart a service this often, because restart is expensive. What I would prefer is to restart a deamon once in 30 seconds or even less often regardless that files are changing all the time. Is there a way to set some debounce/throttle logic?

@wader
Copy link

wader commented Sep 18, 2019

I haven't done exactly this but i've used various tricks with sleep with various success. Maybe something like this:

{
	daemon: echo build ; exec sleep 30
}

or maybe

{
        daemon: while true; do echo > dummy ; sleep 30 ; done
}

dummy {
        prep: echo build
}

@pavel-kolesnikov
Copy link

hopefully fixed in #101

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants