Skip to content

Commit 67ed700

Browse files
Initial gh-pages setup
- Landing page with dynamic version from update.json - Platform detection for smart download links - GitHub Actions workflow to build and deploy
0 parents  commit 67ed700

7 files changed

Lines changed: 224 additions & 0 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Deploy
2+
3+
on:
4+
push:
5+
branches: [gh-pages]
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
13+
concurrency:
14+
group: pages
15+
cancel-in-progress: true
16+
17+
jobs:
18+
build:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: actions/checkout@v4
22+
23+
- name: Build
24+
run: |
25+
mkdir -p dist
26+
cp -r site/* dist/
27+
cp update.json dist/
28+
cp .nojekyll dist/
29+
30+
- name: Upload artifact
31+
uses: actions/upload-pages-artifact@v3
32+
with:
33+
path: dist
34+
35+
deploy:
36+
needs: build
37+
runs-on: ubuntu-latest
38+
environment:
39+
name: github-pages
40+
url: ${{ steps.deployment.outputs.page_url }}
41+
steps:
42+
- name: Deploy to GitHub Pages
43+
id: deployment
44+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
dist/

.nojekyll

Whitespace-only changes.

build.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
# Build script for gh-pages
3+
# Copies site/ contents and update.json to dist/
4+
5+
set -e
6+
7+
rm -rf dist
8+
mkdir -p dist
9+
10+
cp -r site/* dist/
11+
cp update.json dist/
12+
cp .nojekyll dist/
13+
14+
echo "Built to dist/"

site/icon.png

12.1 KB
Loading

site/index.html

Lines changed: 159 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,159 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<title>Kore - Kubernetes IDE</title>
7+
<meta name="description" content="A lightweight, open-source Kubernetes IDE built with Tauri and Svelte">
8+
<link rel="icon" type="image/png" href="icon.png">
9+
<style>
10+
* { margin: 0; padding: 0; box-sizing: border-box; }
11+
:root {
12+
--bg: #0a0a0f;
13+
--text: #f0f0f5;
14+
--text-muted: #8888aa;
15+
--accent: #4285f4;
16+
--accent-hover: #5a9bff;
17+
}
18+
body {
19+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
20+
background: var(--bg);
21+
color: var(--text);
22+
min-height: 100vh;
23+
display: flex;
24+
flex-direction: column;
25+
align-items: center;
26+
justify-content: center;
27+
padding: 2rem;
28+
}
29+
.container { text-align: center; max-width: 400px; }
30+
.logo {
31+
width: 128px;
32+
height: 128px;
33+
margin-bottom: 1.5rem;
34+
filter: drop-shadow(0 4px 24px rgba(66, 133, 244, 0.3));
35+
}
36+
h1 {
37+
font-size: 2.5rem;
38+
font-weight: 600;
39+
letter-spacing: -0.02em;
40+
margin-bottom: 0.5rem;
41+
}
42+
.tagline {
43+
color: var(--text-muted);
44+
font-size: 1rem;
45+
margin-bottom: 2rem;
46+
}
47+
.version {
48+
display: inline-block;
49+
background: rgba(66, 133, 244, 0.15);
50+
color: var(--accent);
51+
padding: 0.35rem 0.75rem;
52+
border-radius: 9999px;
53+
font-size: 0.875rem;
54+
font-weight: 500;
55+
margin-bottom: 1.5rem;
56+
}
57+
.download-btn {
58+
display: inline-flex;
59+
align-items: center;
60+
gap: 0.5rem;
61+
background: var(--accent);
62+
color: white;
63+
text-decoration: none;
64+
padding: 0.875rem 1.75rem;
65+
border-radius: 8px;
66+
font-size: 1rem;
67+
font-weight: 500;
68+
transition: background 0.15s, transform 0.15s;
69+
}
70+
.download-btn:hover {
71+
background: var(--accent-hover);
72+
transform: translateY(-1px);
73+
}
74+
.download-btn svg { width: 18px; height: 18px; }
75+
.platform { color: var(--text-muted); font-size: 0.8rem; margin-top: 0.75rem; }
76+
.links { margin-top: 3rem; display: flex; gap: 1.5rem; justify-content: center; }
77+
.links a {
78+
color: var(--text-muted);
79+
text-decoration: none;
80+
font-size: 0.875rem;
81+
transition: color 0.15s;
82+
}
83+
.links a:hover { color: var(--text); }
84+
.loading { opacity: 0.5; }
85+
</style>
86+
</head>
87+
<body>
88+
<div class="container">
89+
<img src="icon.png" alt="Kore" class="logo">
90+
<h1>Kore</h1>
91+
<p class="tagline">Kubernetes IDE</p>
92+
<div class="version loading" id="version">Loading...</div>
93+
<a href="#" class="download-btn" id="download-btn">
94+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
95+
<path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/>
96+
<polyline points="7 10 12 15 17 10"/>
97+
<line x1="12" y1="15" x2="12" y2="3"/>
98+
</svg>
99+
<span id="download-text">Download</span>
100+
</a>
101+
<p class="platform" id="platform"></p>
102+
<div class="links">
103+
<a href="https://github.com/DEVtheOPS/kore">GitHub</a>
104+
<a href="https://github.com/DEVtheOPS/kore/releases">All Releases</a>
105+
</div>
106+
</div>
107+
<script>
108+
const REPO = 'DEVtheOPS/kore';
109+
function detectPlatform() {
110+
const ua = navigator.userAgent.toLowerCase();
111+
if (ua.includes('mac')) return { os: 'macos', arch: ua.includes('arm') ? 'aarch64' : 'x86_64' };
112+
if (ua.includes('win')) return { os: 'windows', arch: 'x86_64' };
113+
if (ua.includes('linux')) return { os: 'linux', arch: 'x86_64' };
114+
return null;
115+
}
116+
function getPlatformKey(p) {
117+
if (!p) return null;
118+
if (p.os === 'macos') return `darwin-${p.arch}`;
119+
if (p.os === 'windows') return 'windows-x86_64';
120+
if (p.os === 'linux') return 'linux-x86_64';
121+
return null;
122+
}
123+
function getPlatformLabel(p) {
124+
if (!p) return '';
125+
const labels = { 'macos-aarch64': 'macOS (Apple Silicon)', 'macos-x86_64': 'macOS (Intel)', 'windows-x86_64': 'Windows', 'linux-x86_64': 'Linux' };
126+
return labels[`${p.os}-${p.arch}`] || '';
127+
}
128+
async function init() {
129+
const versionEl = document.getElementById('version');
130+
const downloadBtn = document.getElementById('download-btn');
131+
const downloadText = document.getElementById('download-text');
132+
const platformEl = document.getElementById('platform');
133+
try {
134+
const res = await fetch('update.json');
135+
const data = await res.json();
136+
versionEl.textContent = `v${data.version}`;
137+
versionEl.classList.remove('loading');
138+
const platform = detectPlatform();
139+
const platformKey = getPlatformKey(platform);
140+
if (platformKey && data.platforms[platformKey]) {
141+
downloadBtn.href = data.platforms[platformKey].url;
142+
downloadText.textContent = `Download for ${getPlatformLabel(platform)}`;
143+
platformEl.textContent = `v${data.version}`;
144+
} else {
145+
downloadBtn.href = `https://github.com/${REPO}/releases/latest`;
146+
downloadText.textContent = 'View Downloads';
147+
platformEl.textContent = 'All platforms available';
148+
}
149+
} catch (e) {
150+
versionEl.textContent = 'Latest';
151+
versionEl.classList.remove('loading');
152+
downloadBtn.href = `https://github.com/${REPO}/releases/latest`;
153+
downloadText.textContent = 'View Releases';
154+
}
155+
}
156+
init();
157+
</script>
158+
</body>
159+
</html>

update.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"version": "0.0.0",
3+
"notes": "No releases yet",
4+
"pub_date": "2026-01-01T00:00:00Z",
5+
"platforms": {}
6+
}

0 commit comments

Comments
 (0)