mirror of
https://github.com/architectury/architectury-loom.git
synced 2026-04-02 05:27:43 -05:00
Add support for project ATs
This commit is contained in:
@@ -26,6 +26,7 @@ package net.fabricmc.loom.util;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
|
||||
import com.google.common.hash.HashCode;
|
||||
import com.google.common.hash.Hashing;
|
||||
@@ -67,4 +68,9 @@ public class Checksum {
|
||||
throw new RuntimeException("Failed to get file hash");
|
||||
}
|
||||
}
|
||||
|
||||
public static byte[] sha256(String string) {
|
||||
HashCode hash = Hashing.sha256().hashString(string, StandardCharsets.UTF_8);
|
||||
return hash.asBytes();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user