forked from Christopherdominic/soroban-ajo
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·76 lines (66 loc) · 1.85 KB
/
Copy pathsetup.sh
File metadata and controls
executable file
·76 lines (66 loc) · 1.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#!/bin/bash
# Drips Monorepo Quick Start Script
# This script sets up the entire development environment
set -e
echo "🚀 Drips Monorepo Setup"
echo "======================="
echo ""
# Check Node.js
if ! command -v node &> /dev/null; then
echo "❌ Node.js not found. Please install Node.js 18+ first."
exit 1
fi
NODE_VERSION=$(node -v | cut -d'v' -f2 | cut -d'.' -f1)
if [ "$NODE_VERSION" -lt 18 ]; then
echo "❌ Node.js version must be 18 or higher. Current: $(node -v)"
exit 1
fi
echo "✅ Node.js $(node -v) found"
# Install root dependencies
echo ""
echo "📦 Installing root dependencies..."
npm install
# Install frontend dependencies
echo ""
echo "📦 Installing frontend dependencies..."
cd frontend
if [ ! -f ".env.local" ]; then
echo "📝 Creating frontend/.env.local from example..."
cp .env.example .env.local
echo "⚠️ Please edit frontend/.env.local with your configuration"
fi
npm install
cd ..
# Install backend dependencies
echo ""
echo "📦 Installing backend dependencies..."
cd backend
if [ ! -f ".env" ]; then
echo "📝 Creating backend/.env from example..."
cp .env.example .env
echo "⚠️ Please edit backend/.env with your configuration"
fi
npm install
cd ..
echo ""
echo "✅ Setup complete!"
echo ""
echo "📋 Next steps:"
echo ""
echo "1. Configure environment variables:"
echo " - Edit frontend/.env.local"
echo " - Edit backend/.env"
echo ""
echo "2. Deploy smart contract (if not done):"
echo " cd contracts/ajo"
echo " stellar contract build"
echo " stellar contract deploy --wasm target/wasm32-unknown-unknown/release/ajo.wasm --network testnet"
echo ""
echo "3. Start development:"
echo " npm run dev"
echo ""
echo " Or separately:"
echo " npm run dev:frontend # http://localhost:3000"
echo " npm run dev:backend # http://localhost:3001"
echo ""
echo "Happy coding! 🎉"