From c100bd0c4b0d90df863205ece373a4b4988455dd Mon Sep 17 00:00:00 2001 From: Thiago Kenji Okada Date: Wed, 6 Oct 2021 00:50:51 -0300 Subject: [PATCH] Makefile: improvements (#2374) - Add NIXPKGS_REV, so we can pass arbitrary revisions for testing (for example, `release-21.05` so we can test backports). - Add format target, that calls the format script. --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index b3d57978b..0fe294734 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ -.PHONY: all all-tests test -NIX_PATH := nixpkgs=https://github.com/NixOS/nixpkgs/archive/nixpkgs-unstable.tar.gz +.PHONY: all all-tests test format +NIXPKGS_REV := nixpkgs-unstable +NIX_PATH := nixpkgs=https://github.com/NixOS/nixpkgs/archive/${NIXPKGS_REV}.tar.gz all: all-tests @@ -11,3 +12,6 @@ ifndef TEST $(error Use 'make test TEST=' to run desired test) endif nix-shell --pure tests -I ${NIX_PATH} -A run.${TEST} + +format: + ./format