3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/networking/instant-messengers/riot/update-riot-desktop.sh
Milan Pässler a9ae2c055c riot-desktop: use yarn2nix-moretea
Now that we have yarn2nix-moretea in the tree, we can use that instead of the vendored version that was introduced when yarn2nix was removed previously. Also add an update script.
2019-08-26 23:59:58 +02:00

18 lines
626 B
Bash
Executable file

#!/usr/bin/env nix-shell
#!nix-shell -I nixpkgs=../../../../../ -i bash -p wget yarn2nix-moretea.yarn2nix
set -euo pipefail
if [ "$#" -ne 1 ] || [[ "$1" == -* ]]; then
echo "Regenerates the Yarn dependency lock files for the riot-desktop package."
echo "Usage: $0 <git release tag>"
exit 1
fi
RIOT_WEB_SRC="https://raw.githubusercontent.com/vector-im/riot-web/$1"
wget "$RIOT_WEB_SRC/electron_app/package.json" -O riot-desktop-package.json
wget "$RIOT_WEB_SRC/electron_app/yarn.lock" -O riot-desktop-yarndeps.lock
yarn2nix --lockfile=riot-desktop-yarndeps.lock > riot-desktop-yarndeps.nix
rm riot-desktop-yarndeps.lock