mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 06:53:01 +00:00
dictdDBs.wordnet: fix reproducibility with faketime
This commit is contained in:
parent
fe5f8b9c47
commit
e65dc530ba
@ -1,10 +1,10 @@
|
||||
{lib, stdenv, python3, wordnet, writeScript}:
|
||||
{lib, stdenv, python3, wordnet, writeScript, libfaketime}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "542";
|
||||
pname = "dict-db-wordnet";
|
||||
|
||||
buildInputs = [python3 wordnet];
|
||||
buildInputs = [python3 wordnet libfaketime];
|
||||
convert = ./wordnet_structures.py;
|
||||
|
||||
builder = writeScript "builder.sh" ''
|
||||
@ -16,7 +16,8 @@ stdenv.mkDerivation rec {
|
||||
DATA="$DATA `echo $i | sed -e s,data,index,` $i";
|
||||
done
|
||||
|
||||
python ${convert} $DATA
|
||||
source_date=$(date --utc --date=@$SOURCE_DATE_EPOCH "+%F %T")
|
||||
faketime -f "$source_date" python ${convert} $DATA
|
||||
echo en_US.UTF-8 > locale
|
||||
'';
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user