mirror of
https://github.com/RGBCube/alejandra
synced 2025-07-29 03:27:44 +00:00
17 lines
362 B
Bash
Executable file
17 lines
362 B
Bash
Executable file
#! /usr/bin/env sh
|
|
|
|
set -eux
|
|
|
|
if ! command -v nix-build; then
|
|
echo 'ERROR: this pre-commit hook requires "nix-build" to be installed first'
|
|
exit 1
|
|
fi
|
|
|
|
echo INFO: building Alejandra
|
|
|
|
nix-build \
|
|
--out-link result-alejandra \
|
|
https://github.com/kamadorueda/alejandra/tarball/4.0.0
|
|
|
|
echo INFO: running Alejandra:
|
|
result-alejandra/bin/alejandra -- -q "${@}"
|