fix: amélioration gestion erreurs avec set +e pour diagnostic
- Désactivation temporaire de set -e pour voir toutes les erreurs - Capture du code de sortie du script - Affichage du contenu de Navigation.tsx en cas d'échec - Réactivation de set -e à la fin
This commit is contained in:
@@ -75,12 +75,22 @@ RUN mkdir -p .techradar/data && \
|
|||||||
test -f public/team.html && echo "✅ public/team.html existe" || echo "❌ public/team.html n'existe pas"
|
test -f public/team.html && echo "✅ public/team.html existe" || echo "❌ public/team.html n'existe pas"
|
||||||
|
|
||||||
# Créer la page Next.js /team et modifier Navigation
|
# Créer la page Next.js /team et modifier Navigation
|
||||||
RUN chmod +x scripts/create-team-page.sh && \
|
# Désactiver temporairement set -e pour cette section pour voir toutes les erreurs
|
||||||
|
RUN set +e && \
|
||||||
|
chmod +x scripts/create-team-page.sh && \
|
||||||
echo "🚀 Exécution de create-team-page.sh..." && \
|
echo "🚀 Exécution de create-team-page.sh..." && \
|
||||||
echo "📋 État de Navigation.tsx AVANT modification:" && \
|
echo "📋 État de Navigation.tsx AVANT modification:" && \
|
||||||
(grep -A 3 'href="/overview"' .techradar/src/components/Navigation/Navigation.tsx || echo "Pattern overview non trouvé") && \
|
(grep -A 3 'href="/overview"' .techradar/src/components/Navigation/Navigation.tsx || echo "Pattern overview non trouvé") && \
|
||||||
echo "" && \
|
echo "" && \
|
||||||
(./scripts/create-team-page.sh || (echo "❌ Script create-team-page.sh a échoué" && exit 1)) && \
|
./scripts/create-team-page.sh; \
|
||||||
|
SCRIPT_EXIT=$?; \
|
||||||
|
echo "Script exit code: $SCRIPT_EXIT" && \
|
||||||
|
if [ $SCRIPT_EXIT -ne 0 ]; then \
|
||||||
|
echo "❌ Script create-team-page.sh a échoué avec code $SCRIPT_EXIT"; \
|
||||||
|
echo "📄 Contenu de Navigation.tsx après échec:"; \
|
||||||
|
cat .techradar/src/components/Navigation/Navigation.tsx 2>/dev/null || echo "Fichier non accessible"; \
|
||||||
|
exit 1; \
|
||||||
|
fi && \
|
||||||
echo "✅ Script create-team-page.sh terminé" && \
|
echo "✅ Script create-team-page.sh terminé" && \
|
||||||
echo "" && \
|
echo "" && \
|
||||||
echo "📋 Vérification de Navigation.tsx:" && \
|
echo "📋 Vérification de Navigation.tsx:" && \
|
||||||
@@ -103,7 +113,8 @@ RUN chmod +x scripts/create-team-page.sh && \
|
|||||||
echo "📁 Contenu de .techradar/src/pages/:"; \
|
echo "📁 Contenu de .techradar/src/pages/:"; \
|
||||||
ls -la .techradar/src/pages/ 2>/dev/null || echo "Dossier pages/ non trouvé"; \
|
ls -la .techradar/src/pages/ 2>/dev/null || echo "Dossier pages/ non trouvé"; \
|
||||||
exit 1; \
|
exit 1; \
|
||||||
fi
|
fi && \
|
||||||
|
set -e
|
||||||
|
|
||||||
# Builder l'application en mode production pour éviter Fast Refresh
|
# Builder l'application en mode production pour éviter Fast Refresh
|
||||||
# Utiliser WORKDIR pour changer de répertoire de manière fiable
|
# Utiliser WORKDIR pour changer de répertoire de manière fiable
|
||||||
|
|||||||
Reference in New Issue
Block a user