Files
malio-layer-ui/pre-commit
tristan 2a66739040
All checks were successful
Release / release (push) Successful in 57s
Ajout de composant (#7)
| Numéro du ticket | Titre du ticket |
|------------------|-----------------|
|                  |                 |

## Description de la PR

## Modification du .env

## Check list

- [ ] Pas de régression
- [ ] TU/TI/TF rédigée
- [ ] TU/TI/TF OK
- [ ] CHANGELOG modifié

Co-authored-by: kevin <kevin@yuno.malio.fr>
Reviewed-on: #7
Co-authored-by: tristan <tristan@yuno.malio.fr>
Co-committed-by: tristan <tristan@yuno.malio.fr>
2026-03-08 19:00:24 +00:00

29 lines
718 B
Bash

#!/bin/sh
set -e
echo "######### Pre-commit hook start #############"
# Prefer the exact Node version from .nvmrc for hooks (IDE + CLI consistency).
if [ -f ".nvmrc" ]; then
NVM_VERSION="$(tr -d '\r\n' < .nvmrc)"
NVM_VERSION="${NVM_VERSION#v}"
NVM_BIN="$HOME/.nvm/versions/node/v$NVM_VERSION/bin"
if [ -x "$NVM_BIN/node" ] && [ -x "$NVM_BIN/npm" ]; then
PATH="$NVM_BIN:$PATH"
export PATH
fi
fi
if ! command -v npm >/dev/null 2>&1; then
echo "npm introuvable dans le hook. Abandon du commit."
exit 1
fi
echo "Node $(node -v) / npm $(npm -v)"
echo "--- make pre-commit start ---"
make pre-commit
echo "--- make pre-commit finished ---"
echo "All checks passed. Proceeding with commit."
exit 0