OXYGENHUB

ci: one build identity for CI states, so cached targets stay fresh (refs andymccall/oxygenflow#52) 3a01077da29a

The rust sandbox sets OXY_BUILD=ci, and the hub's and oh's build scripts
watch FLOW_HEADS only when OXY_BUILD does not name the build: a push no
longer reruns them and recompiles the whole crate in build, clippy and
test. dist sets the release's own identity as before.
Author
Andy McCall @andymccall <[email protected]>
When
· 2026-10-13 16:11 UTC
Signature
✔ signed by Andy McCall
Hash
3a01077da29aabb3ce6154e495f4d2064756cdef5094f011eb0da88e1fe60687
Depends on
045f967db8f2 380996db84e5 745d225de344 e9bfea8e26db
Depended on by
nothing yet
In bookmarks
api-unknown-fields cancel-landed-runs diffusion-pin-bookmark draft-ready main oh-comment-body-file proposal-list-fast
In tags
v0.5.0 v0.5.1 v0.5.2 v0.6.0 v0.6.1 v0.7.0 v0.8.0 v0.9.0 v0.9.1 v0.9.11 v0.9.15 v0.9.16 v0.9.19 v0.9.2 v0.9.20 v0.9.21 v0.9.22 v0.9.23 v0.9.24 v0.9.3 v0.9.4 v0.9.5 v0.9.6 v0.9.7 v0.9.8 v0.9.9
Edits
5 atoms, 0 tree operations, 3 files

Browse the tree at this change

modified .flow/pipeline.kdl +4 −0
…
23 unchanged lines
24 24
        CARGO_PROFILE_DEV_DEBUG "0"
25 25
        CARGO_PROFILE_TEST_DEBUG "0"
26 26
        CARGO_PROFILE_RELEASE_DEBUG "0"
27 +
        // One build identity for every CI state, so a cached target stays
28 +
        // fresh from one push to the next (oxygenflow#52); dist sets the
29 +
        // release's own.
30 +
        OXY_BUILD "ci"
27 31
    }
28 32
}
29 33
…
47 unchanged lines
modified crates/hub/build.rs +5 −1
…
2 unchanged lines
3 3
//! building, else "local build".
4 4
fn main() {
5 5
    println!("cargo:rerun-if-env-changed=OXY_BUILD");
6 -
    println!("cargo:rerun-if-env-changed=FLOW_HEADS");
6 +
    // The heads name the build only when OXY_BUILD does not: a CI job that
7 +
    // sets it stays fresh from one state to the next (oxygenflow#52).
8 +
    if !std::env::var("OXY_BUILD").is_ok_and(|b| !b.trim().is_empty()) {
9 +
        println!("cargo:rerun-if-env-changed=FLOW_HEADS");
10 +
    }
7 11
    // The migrations `sqlx::migrate!` embeds.
8 12
    println!("cargo:rerun-if-changed=migrations");
9 13
    let build = std::env::var("OXY_BUILD")
…
13 unchanged lines
modified crates/oh/build.rs +5 −1
…
2 unchanged lines
3 3
//! building, else "local build".
4 4
fn main() {
5 5
    println!("cargo:rerun-if-env-changed=OXY_BUILD");
6 -
    println!("cargo:rerun-if-env-changed=FLOW_HEADS");
6 +
    // The heads name the build only when OXY_BUILD does not: a CI job that
7 +
    // sets it stays fresh from one state to the next (oxygenflow#52).
8 +
    if !std::env::var("OXY_BUILD").is_ok_and(|b| !b.trim().is_empty()) {
9 +
        println!("cargo:rerun-if-env-changed=FLOW_HEADS");
10 +
    }
7 11
    let build = std::env::var("OXY_BUILD")
8 12
        .ok()
9 13
        .map(|b| b.trim().to_string())
…
11 unchanged lines