diff options
author | iximeow <me@iximeow.net> | 2023-07-04 18:33:57 -0700 |
---|---|---|
committer | iximeow <me@iximeow.net> | 2023-07-04 18:33:57 -0700 |
commit | d3b9a921d25412ffbafb9b9b500620aa500d55ac (patch) | |
tree | ff22e732b070839af54908259abdedc293a7dc67 /src | |
parent | 138800914aa38f25db2788a94a0327c692e29557 (diff) |
actually set Build.sha
Diffstat (limited to 'src')
-rw-r--r-- | src/lua/mod.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lua/mod.rs b/src/lua/mod.rs index 89ff4c2..6c4a281 100644 --- a/src/lua/mod.rs +++ b/src/lua/mod.rs @@ -365,6 +365,8 @@ impl BuildEnv { ] ).unwrap(); build_functions.set("environment", build_environment).unwrap(); + let current_commit = self.job.lock().unwrap().job.commit.clone(); + build_functions.set("sha", lua_ctx.create_string(current_commit.as_bytes()).unwrap()).unwrap(); let globals = lua_ctx.globals(); globals.set("Build", build_functions).unwrap(); |