-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·82 lines (69 loc) · 2.36 KB
/
setup.sh
File metadata and controls
executable file
·82 lines (69 loc) · 2.36 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
77
78
79
80
81
82
#!/bin/bash
# ─────────────────────────────────────────────
# ZenCode Assistant — Setup Script
# Mac / Linux
# v1.7.4 — The CEO of Water
# ─────────────────────────────────────────────
echo ""
echo " ☯️ ZenCode Assistant — Setup"
echo " ─────────────────────────────"
echo ""
# Step 1: Check if Ollama is installed
if ! command -v ollama &> /dev/null; then
echo " Presence: Ollama not found."
echo " Action: Installing Ollama automatically via curl..."
echo " ─────────────────────────────"
echo ""
# Official Ollama install script
if curl -fsSL https://ollama.com/install.sh | sh; then
echo ""
echo " ✓ Ollama installed successfully."
echo ""
else
echo ""
echo " ✗ Automatic installation failed."
echo " Please download it manually from: https://ollama.com"
echo " Then run this script again."
echo ""
exit 1
fi
else
echo " ✓ Ollama is already present."
fi
echo ""
# Step 2: Pull the base model
echo " Acquisition: Pulling gemma3:4b (~3.3 GB)..."
echo " Grab a coffee. This runs once. ☕"
echo ""
if ! ollama pull gemma3:4b; then
echo ""
echo " ✗ Failed to pull gemma3:4b. Check your connection and try again."
echo ""
exit 1
fi
echo ""
echo " ✓ gemma3:4b pulled successfully."
echo ""
# Step 3: Create ZenCode Assistant from the Modelfile
echo " Creation: Building ZenCode-Assistant-v1.7.4..."
if ! ollama create zen_code -f Modelfile-ZenCode-Assistant; then
echo ""
echo " ✗ Failed to create zen_code. Check the Modelfile and try again."
echo ""
exit 1
fi
# Step 3b: Verify the model actually exists in Ollama
if ! ollama list | grep -qi "zen_code"; then
echo ""
echo " ✗ zen_code was not found in ollama list. Something went wrong."
echo ""
exit 1
fi
echo ""
echo " ✓ Done. zen_code is here."
echo ""
# Step 4: Launch
echo " Activation: Launching ZenCode Assistant..."
echo " ─────────────────────────────"
echo ""
ollama run zen_code