Executing drone build start <repo>
raises an invalid syntax exception.
drone build start the-mast/NewsDayAfricaTheme
strconv.ParseInt: parsing "": invalid syntax
drone -v
drone version 0.5.0+dev
Executing drone build start <repo>
raises an invalid syntax exception.
drone build start the-mast/NewsDayAfricaTheme
strconv.ParseInt: parsing "": invalid syntax
drone -v
drone version 0.5.0+dev
This command (re)starts a build from an existing build number, so you always need to provide a build number.
drone build start {repo} {build}
This re-starts a build number 5
drone build start octocat/hello-world 5
This re-starts build number 5 with a new build number:
drone build start --fork octocat/hello-world 5
This re-starts the latest build for the master branch. This is what you would use for a nightly build job, for example:
drone build start --fork octocat/hello-world \
$(drone build last --format="{{ .Number }}" --branch=master octocat/hello-world)
Oh, that makes sense. Thanks a lot!
Thanks for you help.
One more quick question, is there any way to trigger the first build if there are none that have run already?
Drone is designed to closely integrate into your VCS workflow. it does this by relying on webhooks coming from a supported VCS to trigger builds. Because of this, there is no way to manually start a build using either the UI or the CLI (with the exception of drone deploy
).
Besides this, Drone needs a reference to the exact version of the project you’re trying to build (e.g. a Git commit sha). You can start builds by pushing commits, creating tags, or updating pull requests. Drone will only build exact versions. When restarting an existing build, Drone will build that exact version of your project again. As such, this is not a viable option if you’ve changed the project and you want Drone to build those changes.
To make good use of Drone, your workflow should make good use of VCS features.
I hope this helps you get started with Drone.