New projects created: - michangarrito (marketplace mobile) - template-saas (SaaS template) - clinica-dental (dental ERP) - clinica-veterinaria (veterinary ERP) Architecture updates: - Move catalog from core/ to shared/ - Add MCP servers structure and templates - Add git management scripts - Update SUBREPOSITORIOS.md with 15 new repos - Update .gitignore for new projects Repository infrastructure: - 4 main repositories - 11 subrepositorios - Gitea remotes configured 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
112 lines
3.6 KiB
Bash
Executable File
112 lines
3.6 KiB
Bash
Executable File
#!/bin/bash
|
|
# =============================================================================
|
|
# Script: Crear repositorios en Gitea para proyectos del workspace
|
|
# Fecha: 2025-01-04
|
|
# =============================================================================
|
|
|
|
GITEA_URL="http://72.60.226.4:3000"
|
|
GITEA_USER="rckrdmrd"
|
|
SSH_HOST="gitea-server"
|
|
|
|
# Colores
|
|
GREEN='\033[0;32m'
|
|
YELLOW='\033[1;33m'
|
|
RED='\033[0;31m'
|
|
NC='\033[0m'
|
|
|
|
echo -e "${GREEN}=== Creando repositorios en Gitea ===${NC}"
|
|
echo ""
|
|
|
|
# Función para crear repositorio via API (requiere token)
|
|
# Por ahora usamos git init y push
|
|
create_repo() {
|
|
local repo_name=$1
|
|
local description=$2
|
|
local local_path=$3
|
|
|
|
echo -e "${YELLOW}Creando: $repo_name${NC}"
|
|
|
|
if [ -n "$local_path" ] && [ -d "$local_path" ]; then
|
|
cd "$local_path"
|
|
|
|
# Verificar si ya tiene .git
|
|
if [ -d ".git" ]; then
|
|
echo " Ya tiene .git, verificando remote..."
|
|
existing_remote=$(git remote get-url origin 2>/dev/null)
|
|
if [ -n "$existing_remote" ]; then
|
|
echo " Remote existente: $existing_remote"
|
|
return 0
|
|
fi
|
|
else
|
|
git init
|
|
fi
|
|
|
|
# Configurar remote
|
|
git remote add origin git@${SSH_HOST}:${GITEA_USER}/${repo_name}.git 2>/dev/null || \
|
|
git remote set-url origin git@${SSH_HOST}:${GITEA_USER}/${repo_name}.git
|
|
|
|
echo -e " ${GREEN}Configurado: git@${SSH_HOST}:${GITEA_USER}/${repo_name}.git${NC}"
|
|
else
|
|
echo -e " ${RED}Path no existe: $local_path${NC}"
|
|
fi
|
|
}
|
|
|
|
# =============================================================================
|
|
# REPOSITORIOS PRINCIPALES (proyectos completos)
|
|
# =============================================================================
|
|
|
|
echo "--- Repositorios Principales ---"
|
|
|
|
# erp-construccion (subrepos ya existen)
|
|
create_repo "erp-construccion" "ERP para construccion - proyecto principal" \
|
|
"/home/isem/workspace-v1/projects/erp-construccion"
|
|
|
|
# erp-core (subrepos ya existen)
|
|
create_repo "erp-core" "ERP Core - modulos base compartidos" \
|
|
"/home/isem/workspace-v1/projects/erp-core"
|
|
|
|
# erp-mecanicas-diesel (subrepos ya existen)
|
|
create_repo "erp-mecanicas-diesel" "ERP para mecanicas diesel" \
|
|
"/home/isem/workspace-v1/projects/erp-mecanicas-diesel"
|
|
|
|
# erp-suite
|
|
create_repo "erp-suite" "ERP Suite - multi-vertical" \
|
|
"/home/isem/workspace-v1/projects/erp-suite"
|
|
|
|
# erp-clinicas
|
|
create_repo "erp-clinicas" "ERP para clinicas medicas" \
|
|
"/home/isem/workspace-v1/projects/erp-clinicas"
|
|
|
|
# erp-retail
|
|
create_repo "erp-retail" "ERP para retail" \
|
|
"/home/isem/workspace-v1/projects/erp-retail"
|
|
|
|
# erp-vidrio-templado
|
|
create_repo "erp-vidrio-templado" "ERP para vidrio templado" \
|
|
"/home/isem/workspace-v1/projects/erp-vidrio-templado"
|
|
|
|
# trading-platform
|
|
create_repo "trading-platform" "Plataforma de trading" \
|
|
"/home/isem/workspace-v1/projects/trading-platform"
|
|
|
|
# betting-analytics
|
|
create_repo "betting-analytics" "Analytics para apuestas deportivas" \
|
|
"/home/isem/workspace-v1/projects/betting-analytics"
|
|
|
|
# inmobiliaria-analytics
|
|
create_repo "inmobiliaria-analytics" "Analytics inmobiliario" \
|
|
"/home/isem/workspace-v1/projects/inmobiliaria-analytics"
|
|
|
|
# platform_marketing_content
|
|
create_repo "platform-marketing-content" "Plataforma de marketing y contenido" \
|
|
"/home/isem/workspace-v1/projects/platform_marketing_content"
|
|
|
|
echo ""
|
|
echo -e "${GREEN}=== Repositorios principales configurados ===${NC}"
|
|
echo ""
|
|
echo "Para crear los repositorios en Gitea, ejecuta desde cada proyecto:"
|
|
echo " git push -u origin main"
|
|
echo ""
|
|
echo "O crea los repositorios vacios primero en:"
|
|
echo " ${GITEA_URL}/${GITEA_USER}"
|