Strider-CD / strider-simple-runner

Easy-to-configure in-process Runner implementation for Strider.
MIT License
3 stars 18 forks source link

Configure the number of preserved data directories. #31

Closed smashwilson closed 8 years ago

smashwilson commented 8 years ago

Adds a control to the runner's configuration page to adjust the number of most recent data directories to preserve for each job.

Fixes #28.

smashwilson commented 8 years ago

Interesting. It looks like dirkeeper deletes the oldest count entries, rather than what I would expect, which is deleting everything but the most recent count entries. That's certainly what I thought from the README, anyway. It special-cases counts of 0, or greater than the number of subdirectories, to delete everything and nothing, respectively.

Looks like I have another PR to make :wrench:

knownasilya commented 8 years ago

Nice catch.

smashwilson commented 8 years ago

I've opened an upstream PR at FrozenRidge/dirkeeper#2. With some judicious use of npm link, it looks like it's working correctly.

One interesting note is that this keeps the most recent N+1 builds around, because it prunes all but the most recent N then creates the current build's directory. Do you think I should make the configuration setting include the current build (and account for the off-by-one), or leave it as it is?

knownasilya commented 8 years ago

I would account for it.

smashwilson commented 8 years ago

:+1: Can do.

smashwilson commented 8 years ago

Done. This should be ready as soon as that dirkeeper PR is merged and shipped (or we can depend on the git commit, I suppose).

Here's what the configuration looks like:

screen shot 2016-03-23 at 2 36 46 pm