about summary refs log tree commit diff
path: root/tvix/nix-compat/src/nixhash/algos.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/nix-compat/src/nixhash/algos.rs')
-rw-r--r--tvix/nix-compat/src/nixhash/algos.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/tvix/nix-compat/src/nixhash/algos.rs b/tvix/nix-compat/src/nixhash/algos.rs
index d6b0bf47bdb7..45cc242dc330 100644
--- a/tvix/nix-compat/src/nixhash/algos.rs
+++ b/tvix/nix-compat/src/nixhash/algos.rs
@@ -24,6 +24,11 @@ impl Display for HashAlgo {
     }
 }
 
+/// TODO(Raito): this could be automated via macros, I suppose.
+/// But this may be more expensive than just doing it by hand
+/// and ensuring that is kept in sync.
+pub const SUPPORTED_ALGOS: [&str; 4] = ["md5", "sha1", "sha256", "sha512"];
+
 impl TryFrom<&str> for HashAlgo {
     type Error = Error;