diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2024-10-23 18:45:47 +0200 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2024-10-24 09:51:31 +0200 |
commit | 85065024eb4ca2ec1dac4dc7cb1fc8ff8fb238c8 (patch) | |
tree | 8b428bef700e2c5801d3ab96313b6f4d6b9f3b38 /mod/mod-build-force.cxx | |
parent | 295cdbd98a261559e34f8453e149e6be5bafcc5a (diff) |
Add ci_start::rebuild() function
Diffstat (limited to 'mod/mod-build-force.cxx')
-rw-r--r-- | mod/mod-build-force.cxx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/mod/mod-build-force.cxx b/mod/mod-build-force.cxx index ea921e9..8666889 100644 --- a/mod/mod-build-force.cxx +++ b/mod/mod-build-force.cxx @@ -198,6 +198,9 @@ handle (request& rq, response& rs) // connection_ptr conn (build_db_->connection ()); + // NOTE: don't forget to update ci_start::rebuild() if changing anything + // here. + // { transaction t (conn->begin ()); @@ -206,8 +209,11 @@ handle (request& rq, response& rs) if (!build_db_->query_one<package_build> ( query<package_build>::build::id == id, pb) || + pb.archived || (b = move (pb.build))->state == build_state::queued) + { config_expired ("no package build"); + } force_state force (b->state == build_state::built ? force_state::forced |