mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-15 13:37:21 +03:00
Merge pull request #94583 from mweinelt/zigbee2mqtt
zigbee2mqtt: 1.14.1 -> 1.14.2
This commit is contained in:
commit
d1f59cf7b8
@ -370,6 +370,7 @@ in
|
||||
yabar = handleTest ./yabar.nix {};
|
||||
yggdrasil = handleTest ./yggdrasil.nix {};
|
||||
zfs = handleTest ./zfs.nix {};
|
||||
zigbee2mqtt = handleTest ./zigbee2mqtt.nix {};
|
||||
zoneminder = handleTest ./zoneminder.nix {};
|
||||
zookeeper = handleTest ./zookeeper.nix {};
|
||||
zsh-history = handleTest ./zsh-history.nix {};
|
||||
|
@ -1,9 +1,9 @@
|
||||
{ pkgs, stdenv, system, dataDir ? "/opt/zigbee2mqtt/data" }:
|
||||
{ pkgs, stdenv, system, dataDir ? "/opt/zigbee2mqtt/data", nixosTests }:
|
||||
let
|
||||
package = (import ./node.nix { inherit pkgs system; }).package;
|
||||
in
|
||||
package.override rec {
|
||||
version = "1.14.1";
|
||||
version = "1.14.2";
|
||||
reconstructLock = true;
|
||||
|
||||
postInstall = ''
|
||||
@ -20,9 +20,11 @@ package.override rec {
|
||||
owner = "Koenkk";
|
||||
repo = "zigbee2mqtt";
|
||||
rev = version;
|
||||
sha256 = "1g1j634474m6arr3qyvf2bzmjh4qs02rhnfh0dlm8qz8rh3xj2rk";
|
||||
sha256 = "0yv51rds28az5pqzgkprhrzwmky29l1mvqb73l7dbs8qlx8x1x52";
|
||||
};
|
||||
|
||||
passthru.tests.zigbee2mqtt = nixosTests.zigbee2mqtt;
|
||||
|
||||
meta = with pkgs.stdenv.lib; {
|
||||
description = "Zigbee to MQTT bridge using zigbee-shepherd";
|
||||
license = licenses.gpl3;
|
||||
|
@ -1,15 +0,0 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#! nix-shell -i bash -p nodePackages.node2nix nodejs-12_x
|
||||
VERSION=1.14.1
|
||||
ZIGBEE2MQTT=https://raw.githubusercontent.com/Koenkk/zigbee2mqtt/$VERSION
|
||||
|
||||
wget $ZIGBEE2MQTT/package.json
|
||||
wget $ZIGBEE2MQTT/npm-shrinkwrap.json
|
||||
|
||||
node2nix --nodejs-12 \
|
||||
-l npm-shrinkwrap.json \
|
||||
-c node.nix \
|
||||
--bypass-cache \
|
||||
--no-copy-node-env \
|
||||
--node-env ../../development/node-packages/node-env.nix
|
||||
rm package.json npm-shrinkwrap.json
|
4116
pkgs/servers/zigbee2mqtt/node-packages.nix
generated
4116
pkgs/servers/zigbee2mqtt/node-packages.nix
generated
File diff suppressed because it is too large
Load Diff
30
pkgs/servers/zigbee2mqtt/update.sh
Executable file
30
pkgs/servers/zigbee2mqtt/update.sh
Executable file
@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#! nix-shell -i bash -p nodePackages.node2nix nodejs-12_x curl jq nix-update
|
||||
|
||||
CURRENT_VERSION=$(nix eval --raw '(with import ../../.. {}; zigbee2mqtt.version)')
|
||||
TARGET_VERSION=$(curl https://api.github.com/repos/Koenkk/zigbee2mqtt/releases/latest | jq -r ".tag_name")
|
||||
ZIGBEE2MQTT=https://github.com/Koenkk/zigbee2mqtt/raw/$TARGET_VERSION
|
||||
|
||||
if [[ "$CURRENT_VERSION" == "$TARGET_VERSION" ]]; then
|
||||
echo "zigbee2mqtt is up-to-date: ${CURRENT_VERSION}"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
wget $ZIGBEE2MQTT/package.json
|
||||
wget $ZIGBEE2MQTT/npm-shrinkwrap.json
|
||||
|
||||
node2nix --nodejs-12 \
|
||||
-l npm-shrinkwrap.json \
|
||||
-c node.nix \
|
||||
--bypass-cache \
|
||||
--no-copy-node-env \
|
||||
--node-env ../../development/node-packages/node-env.nix
|
||||
rm package.json npm-shrinkwrap.json
|
||||
|
||||
{
|
||||
cd ../../..
|
||||
nix-update --version "$TARGET_VERSION" --build zigbee2mqtt
|
||||
}
|
||||
|
||||
git add ./default.nix ./node-packages.nix ./node.nix
|
||||
git commit -m "zigbee2mqtt: ${CURRENT_VERSION} -> ${TARGET_VERSION}"
|
Loading…
Reference in New Issue
Block a user