diff options
author | Florian Klink <flokli@flokli.de> | 2023-01-23T13·46+0100 |
---|---|---|
committer | flokli <flokli@flokli.de> | 2023-01-23T13·53+0000 |
commit | b0d6e748acbdfb914bfe53c1c91345a408cc8726 (patch) | |
tree | 2ccf468fa9046229103c09813dc2a81741e203fc /tvix/derivation/src/validate.rs | |
parent | fc177af0c1dab6a4504e7e95c63507eb2a942e8f (diff) |
refactor(tvix/derivation): remove DOT_FILE_EXT const r/5739
This is used in few enough places to just inline it. It felt a bit alien in the ATerm construction aswell. write.rs now pleasantly only includes tokens that occur in the ATerm representation. Change-Id: I524f8d6c1ce9057ff7fd16c6c3efd98467040a44 Reviewed-on: https://cl.tvl.fyi/c/depot/+/7911 Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/derivation/src/validate.rs')
-rw-r--r-- | tvix/derivation/src/validate.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tvix/derivation/src/validate.rs b/tvix/derivation/src/validate.rs index 8a8c1b506911..09b9eea415e5 100644 --- a/tvix/derivation/src/validate.rs +++ b/tvix/derivation/src/validate.rs @@ -1,4 +1,4 @@ -use crate::{derivation::Derivation, write::DOT_FILE_EXT, DerivationError}; +use crate::{derivation::Derivation, DerivationError}; use tvix_store::store_path::StorePath; impl Derivation { @@ -60,7 +60,7 @@ impl Derivation { )); } - if !input_derivation_path.ends_with(DOT_FILE_EXT) { + if !input_derivation_path.ends_with(".drv") { return Err(DerivationError::InvalidInputDerivationPrefix( input_derivation_path.to_string(), )); |