Can one specify a default .drone.yml for when missing from a repo

I have a use case where we have hundreds of R packages in our community with many different maintainers, and I’ld like to set up CI for all of them. They all have .travis.yml files, but only very few have .drone.yml files. The salient point is that it can take a while to get everyone to add .drone.yml files, so is there a way to use a default .drone.yml file if one is not found? I don’t know yet how different the .drone.yml file will need to be for each R package, but perhaps a default configuration will work for most.

1 Like

No, this is one of those places where the fundamental design of Drone, like Travis, won’t accommodate what you’re asking for. Just like Travis requires a .travis.yml file in order to know what to do, Drone requires a .drone.yml file.

Your best bet may be to find a way to script/automate adding a boilerplate .drone.yml file to all of the repositories, either starting from local clones (yes, that’s a lot of repos!), or if they’re on GitHub, by using the GitHub API. Both of these solutions presume that you have write permissions to the repos, which may not be the case. Otherwise, I suspect your Drone adoption will look just like Travis’s was… one repo at a time, as folks figured out how to set things up.

Thanks for your response! Makes sense, and we’ll explore some other options.

Thanks @JaredReisinger! Just a note, Travis does provide a pretty rich set of defaults for a number of programming languages so that many software projects will work just fine without providing .travis.yml. . Travis describes .travis.yml as a mechanism to customize this process. I realize this probably isn’t a priority area , but I do think it’s worth considering where sensible defaults can take the place of mandatory configuration.

Thanks for pointing that out! I missed the “provides a default” part of the Travis docs.

Even if Travis didn’t, I can see where this could be useful, assuming you (well, Drone) could infer the language/platform from the files in the repo. As far as I know, Drone doesn’t do anything of the sort right now, which makes any kind of defaulting really difficult. (I guess it could start with a single, language-ignorant default which might work in the case where you have a one-purpose Drone server… like if sckott’s server were used primary/only for R repos.)