Replace justfile
with run
This commit is contained in:
parent
77aa4db95f
commit
eb677985cb
|
@ -16,7 +16,6 @@
|
||||||
lib = import ./lib { inherit inputs self; };
|
lib = import ./lib { inherit inputs self; };
|
||||||
|
|
||||||
inherit (lib) mkNeovim mkVimPlugin;
|
inherit (lib) mkNeovim mkVimPlugin;
|
||||||
inherit (pkgs) mkShell;
|
|
||||||
|
|
||||||
default = mkVimPlugin { inherit system; };
|
default = mkVimPlugin { inherit system; };
|
||||||
neovim = mkNeovim { inherit system; };
|
neovim = mkNeovim { inherit system; };
|
||||||
|
@ -24,8 +23,6 @@
|
||||||
{
|
{
|
||||||
inherit lib;
|
inherit lib;
|
||||||
|
|
||||||
devShells.${system}.default = mkShell { buildInputs = with pkgs; [ just ]; };
|
|
||||||
|
|
||||||
formatter.${system} = pkgs.nixfmt-rfc-style;
|
formatter.${system} = pkgs.nixfmt-rfc-style;
|
||||||
|
|
||||||
packages.${system} = {
|
packages.${system} = {
|
||||||
|
|
11
justfile
11
justfile
|
@ -1,11 +0,0 @@
|
||||||
_default:
|
|
||||||
just --list
|
|
||||||
|
|
||||||
build profile *args:
|
|
||||||
nix build --json --no-link --print-build-logs ".#{{ profile }}" {{ args }}
|
|
||||||
|
|
||||||
check:
|
|
||||||
nix flake check
|
|
||||||
|
|
||||||
update:
|
|
||||||
nix flake update
|
|
33
run
Executable file
33
run
Executable file
|
@ -0,0 +1,33 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -o errexit
|
||||||
|
set -o nounset
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
function build {
|
||||||
|
local profile="${1:-}"
|
||||||
|
echo ${#}
|
||||||
|
shift 1
|
||||||
|
|
||||||
|
nix build --json --no-link \
|
||||||
|
--print-build-logs ".#${profile}" "${@}"
|
||||||
|
}
|
||||||
|
|
||||||
|
function check {
|
||||||
|
nix flake check
|
||||||
|
}
|
||||||
|
|
||||||
|
function help {
|
||||||
|
printf "%s <task> [args]\n\nTasks:\n" "${0}"
|
||||||
|
|
||||||
|
compgen -A function | grep -v "^_" | cat -n
|
||||||
|
|
||||||
|
printf "\nExtended help:\n Each task has comments for general usage\n"
|
||||||
|
}
|
||||||
|
|
||||||
|
function update {
|
||||||
|
nix flake update
|
||||||
|
}
|
||||||
|
|
||||||
|
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||||
|
time "${@:-help}"
|
Reference in a new issue