Skip to content

Commit f12d037

Browse files
committed
feat: Add universal install script, sponsorship links, and responsive documentation improvements.
1 parent 8e3f7dc commit f12d037

File tree

5 files changed

+341
-15
lines changed

5 files changed

+341
-15
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
[![Go Report Card](https://goreportcard.com/badge/github.com/Bharath-code/git-scope)](https://goreportcard.com/report/github.com/Bharath-code/git-scope)
66
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
77
[![GitHub stars](https://img.shields.io/github/stars/Bharath-code/git-scope)](https://github.com/Bharath-code/git-scope/stargazers)
8+
[![Buy Me A Coffee](https://img.shields.io/badge/Buy%20Me%20A%20Coffee-FFDD00?style=flat&logo=buy-me-a-coffee&logoColor=black)](https://buymeacoffee.com/iam_pbk)
89

910
![git-scope Demo](docs/git-scope-demo-1.webp)
1011

docs/index.html

Lines changed: 193 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -102,10 +102,27 @@
102102
font-family: 'JetBrains Mono', monospace;
103103
}
104104

105+
/* Prevent horizontal overflow globally */
106+
img,
107+
svg,
108+
video,
109+
canvas,
110+
audio,
111+
iframe,
112+
embed,
113+
object {
114+
max-width: 100%;
115+
height: auto;
116+
}
117+
105118
.container {
119+
width: 100%;
120+
/* Ensure container doesn't exceed viewport */
106121
max-width: 1200px;
107122
margin: 0 auto;
108123
padding: 0 2rem;
124+
overflow-x: hidden;
125+
/* Clip anything that sticks out of container */
109126
}
110127

111128
/* Nav */
@@ -179,6 +196,32 @@
179196
color: var(--text-main);
180197
}
181198

199+
.support-btn {
200+
display: flex;
201+
align-items: center;
202+
gap: 0.5rem;
203+
color: #ec4899;
204+
/* Pink-500 for love */
205+
text-decoration: none;
206+
font-size: 0.9rem;
207+
font-weight: 500;
208+
padding: 0.4rem 0.8rem;
209+
border: 1px solid rgba(236, 72, 153, 0.2);
210+
border-radius: 9999px;
211+
background: rgba(236, 72, 153, 0.05);
212+
transition: all 0.2s ease;
213+
}
214+
215+
.support-btn:hover {
216+
background: rgba(236, 72, 153, 0.15);
217+
border-color: rgba(236, 72, 153, 0.4);
218+
transform: translateY(-1px);
219+
}
220+
221+
.support-text {
222+
display: inline;
223+
}
224+
182225
@media (max-width: 768px) {
183226
nav {
184227
/* flex-wrap: wrap; removed to keep items on same line */
@@ -193,6 +236,16 @@
193236
display: none;
194237
}
195238

239+
/* Show only icon on mobile to save space */
240+
.support-text {
241+
display: none;
242+
}
243+
244+
.support-btn {
245+
padding: 0.4rem;
246+
/* Smaller padding for icon-only */
247+
}
248+
196249
.nav-right {
197250
gap: 0.5rem;
198251
/* Tighten gap on mobile */
@@ -232,6 +285,23 @@
232285
margin-bottom: 1.5rem;
233286
}
234287

288+
.hero h1 {
289+
font-size: clamp(2.5rem, 5vw, 4.5rem);
290+
font-weight: 800;
291+
line-height: 1.1;
292+
margin-bottom: 1.5rem;
293+
letter-spacing: -0.02em;
294+
}
295+
296+
@media (max-width: 480px) {
297+
.hero h1 {
298+
font-size: 2.5rem;
299+
/* Force smaller size on mobile */
300+
word-break: break-word;
301+
/* Ensure it wraps */
302+
}
303+
}
304+
235305
.gradient-text {
236306
background: var(--gradient);
237307
-webkit-background-clip: text;
@@ -247,8 +317,72 @@
247317
}
248318

249319
/* Install Tabs */
320+
.install-grid {
321+
display: flex;
322+
gap: 1.5rem;
323+
justify-content: center;
324+
align-items: stretch;
325+
flex-wrap: wrap;
326+
margin-bottom: 1.5rem;
327+
}
328+
329+
.install-option {
330+
flex: 1;
331+
/* Allow it to shrink below 280px on tiny screens, but prefer 300px on desktop */
332+
flex-basis: 300px;
333+
min-width: 0;
334+
display: flex;
335+
flex-direction: column;
336+
}
337+
338+
.install-heading {
339+
text-align: center;
340+
margin-bottom: 0.75rem;
341+
font-size: 0.85rem;
342+
font-weight: 600;
343+
color: var(--primary);
344+
text-transform: uppercase;
345+
letter-spacing: 0.05em;
346+
}
347+
348+
.desktop-only {
349+
display: inline;
350+
}
351+
352+
.mobile-only {
353+
display: none;
354+
}
355+
356+
@media (max-width: 768px) {
357+
.container {
358+
padding: 0 1rem;
359+
/* Reduce padding on mobile to give more space */
360+
}
361+
362+
.desktop-only {
363+
display: none;
364+
}
365+
366+
.mobile-only {
367+
display: inline;
368+
}
369+
370+
.install-grid {
371+
flex-direction: column;
372+
/* Explicitly stack on mobile */
373+
gap: 2rem;
374+
}
375+
376+
.install-option {
377+
width: 100%;
378+
/* Full width on mobile */
379+
flex-basis: auto;
380+
}
381+
}
382+
250383
.install-section {
251-
max-width: 600px;
384+
max-width: 800px;
385+
/* Increased max-width for side-by-side */
252386
margin: 0 auto;
253387
}
254388

@@ -744,6 +878,17 @@
744878
<a href="#blog">Blog</a>
745879
<a href="#contact">Contact</a>
746880
</div>
881+
882+
<!-- Sponsor Button -->
883+
<a href="https://buymeacoffee.com/iam_pbk" target="_blank" class="support-btn"
884+
aria-label="Sponsor Project">
885+
<svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor">
886+
<path
887+
d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z" />
888+
</svg>
889+
<span class="support-text">Sponsor</span>
890+
</a>
891+
747892
<div style="width: 1px; height: 24px; background: rgba(255,255,255,0.1);"></div>
748893
<img src="https://img.shields.io/github/downloads/Bharath-code/git-scope/total?style=flat-square&color=7C3AED&label=Downloads"
749894
alt="Downloads" height="20">
@@ -784,23 +929,57 @@ <h1>Stop <span class="gradient-text">cd-ing.</span> <br> Start Coding.</h1>
784929

785930
<!-- Simplified Install -->
786931
<div class="install-section" style="margin-bottom: 2rem;">
787-
<div class="install-box" onclick="copyInstallCommand()"
788-
style="padding: 1rem; text-align: center; max-width: 500px; margin: 0 auto; display: flex; align-items: center; justify-content: center; gap: 1rem;">
789-
<span class="prompt">$</span>
790-
<span class="cmd" style="font-size: 1.1rem; font-weight: 600;">brew tap Bharath-code/tap && brew
791-
install git-scope</span>
792-
<svg id="copy-icon" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor"
793-
stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-copy"
794-
style="opacity: 0.5; margin-left: auto; transition: all 0.2s;">
795-
<rect x="9" y="9" width="13" height="13" rx="2" ry="2"></rect>
796-
<path d="M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"></path>
797-
</svg>
932+
933+
<div class="install-grid">
934+
<!-- Option 1: Homebrew -->
935+
<div class="install-option">
936+
<div class="install-heading">Homebrew</div>
937+
<div class="install-box" onclick="copyInstallCommand()"
938+
style="padding: 1rem; text-align: center; height: 100%; display: flex; align-items: center; justify-content: center; gap: 0.5rem;">
939+
<span class="prompt">$</span>
940+
<span class="cmd" style="font-size: 0.95rem; font-weight: 600;">brew tap
941+
Bharath-code/tap &&
942+
brew install git-scope</span>
943+
<svg id="copy-icon" width="16" height="16" viewBox="0 0 24 24" fill="none"
944+
stroke="currentColor" stroke-width="2" stroke-linecap="round"
945+
stroke-linejoin="round" class="feather feather-copy"
946+
style="opacity: 0.5; margin-left: auto; min-width: 16px;">
947+
<rect x="9" y="9" width="13" height="13" rx="2" ry="2"></rect>
948+
<path d="M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"></path>
949+
</svg>
950+
</div>
951+
</div>
952+
953+
<!-- Option 2: Script -->
954+
<div class="install-option">
955+
<div class="install-heading">Universal Installer</div>
956+
<div class="install-box" onclick="copyScriptCommand()"
957+
style="padding: 1rem; text-align: center; height: 100%; display: flex; align-items: center; justify-content: center; gap: 0.5rem;">
958+
<span class="prompt">$</span>
959+
<span class="cmd" style="font-size: 0.95rem; font-weight: 600; word-break: break-all;">
960+
<span class="desktop-only">curl -sSL
961+
https://raw.githubusercontent.com/Bharath-code/git-scope/main/scripts/install.sh
962+
| sh</span>
963+
<span class="mobile-only">curl -sSL .../scripts/install.sh | sh</span>
964+
</span>
965+
<svg id="script-copy-icon" width="16" height="16" viewBox="0 0 24 24" fill="none"
966+
stroke="currentColor" stroke-width="2" stroke-linecap="round"
967+
stroke-linejoin="round" class="feather feather-copy"
968+
style="opacity: 0.5; margin-left: auto; min-width: 16px;">
969+
<rect x="9" y="9" width="13" height="13" rx="2" ry="2"></rect>
970+
<path d="M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"></path>
971+
</svg>
972+
<div id="script-copy-feedback"
973+
style="font-size: 0.75rem; color: #27C93F; opacity: 0; transition: opacity 0.2s; position: absolute; bottom: 4px; right: 10px;">
974+
</div>
975+
</div>
976+
</div>
798977
</div>
978+
799979
<div style="margin-top: 1rem;">
800980
<a href="https://github.com/Bharath-code/git-scope/releases" target="_blank"
801981
style="color: var(--text-muted); font-size: 0.9rem; text-decoration: underline;"
802-
id="hero-install-options">View
803-
Windows, Linux & Go Install</a>
982+
id="hero-install-options">View Windows & Go Install</a>
804983
</div>
805984
</div>
806985

docs/main.js

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,28 @@ function showCopyFeedback() {
6969
}, 2000);
7070
}
7171

72+
function copyScriptCommand() {
73+
const command = "curl -sSL https://raw.githubusercontent.com/Bharath-code/git-scope/main/scripts/install.sh | sh";
74+
75+
if (!navigator.clipboard) {
76+
const ta = document.createElement('textarea');
77+
ta.value = command;
78+
document.body.appendChild(ta);
79+
ta.select();
80+
document.execCommand('copy');
81+
document.body.removeChild(ta);
82+
} else {
83+
navigator.clipboard.writeText(command);
84+
}
85+
86+
const feedback = document.getElementById('script-copy-feedback');
87+
if (feedback) {
88+
feedback.style.opacity = '1';
89+
setTimeout(() => { feedback.style.opacity = '0'; }, 2000);
90+
}
91+
trackEvent('script-command-copied', 'Copied curl install command');
92+
}
93+
7294
// ===============================
7395
// CLICK TRACKING
7496
// ===============================

internal/tui/view.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ func (m Model) renderDashboard() string {
9494

9595
// Header with logo on its own line
9696
logo := lipgloss.NewStyle().Bold(true).Foreground(lipgloss.Color("#A78BFA")).Render("git-scope")
97-
version := lipgloss.NewStyle().Foreground(lipgloss.Color("#6B7280")).Render(" v1.2.0")
97+
version := lipgloss.NewStyle().Foreground(lipgloss.Color("#6B7280")).Render(" v1.2.1")
9898
b.WriteString(logo + version)
9999
b.WriteString("\n\n")
100100

0 commit comments

Comments
 (0)