diff --git a/Makefile.am b/Makefile.am index 1964e1d..85238c9 100644 --- a/Makefile.am +++ b/Makefile.am @@ -137,12 +137,10 @@ sync-neurotron: exit 0; \ fi - @# === 1) Verificar remote atual === @cd $(NEUROTRON_DIR) && \ REMOTE_URL=$$(git remote get-url $(NEUROTRON_REMOTE)); \ echo "🔍 Remote atual do Neurotron: $$REMOTE_URL"; \ \ - @# === 2) Se HTTPS → converter para SSH:2222 === if echo $$REMOTE_URL | grep -q '^https://gitea\.neoricalex\.com'; then \ echo "⚠️ Neurotron ainda está em HTTPS. Convertendo para SSH:2222…"; \ SSH_URL=$$(echo $$REMOTE_URL | sed -E 's|https://gitea\.neoricalex\.com[:/]+|ssh://git@gitea.neoricalex.com:2222/|'); \ @@ -150,7 +148,6 @@ sync-neurotron: echo "✅ Remote atualizado: $$SSH_URL"; \ fi; \ \ - @# === 3) Se SSH mas sem porta, forçar porta 2222 === if echo $$REMOTE_URL | grep -q '^ssh://git@gitea\.neoricalex\.com/'; then \ echo "⚠️ SSH sem porta detectado. Ajustando porta 2222…"; \ SSH_URL=$$(echo $$REMOTE_URL | sed -E 's|ssh://git@gitea.neoricalex.com/|ssh://git@gitea.neoricalex.com:2222/|'); \ @@ -158,7 +155,6 @@ sync-neurotron: echo "✅ Remote atualizado: $$SSH_URL"; \ fi - @# === 4) Testar conexão SSH antes do push === @if ssh -T git@gitea.neoricalex.com -p 2222 2>&1 | grep -q "successfully authenticated"; then \ echo "🔐 SSH OK para Neurotron."; \ else \ @@ -166,7 +162,6 @@ sync-neurotron: exit 1; \ fi - @# === 5) Commit + push automático === @cd $(NEUROTRON_DIR) && \ git add -A && \ git commit -m "Auto-commit via make git (triggered by NFDOS)" || echo "Nenhuma modificação no Neurotron."; \