Skip to content

ponderingBGI/SetScreens

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SetScreens

Interactive desktop environments that run entirely in the browser.

HackerOS Preview

Features

  • Browser-based desktop environments with draggable, resizable windows (WinBox)
  • HackerOS — terminal, file explorer, text editor, and right-click context menus
  • Keyboard shortcuts and touch gestures for full navigation
  • GPU-accelerated animations via Motion
  • Raspberry Pi kiosk deployment with auto-update

Quick Start

bun install
bun run dev

Keyboard Shortcuts

Key Action
Enter Launch selected project
Esc Esc Return to home screen
Ctrl+T Open terminal
Ctrl+E Open file explorer
Ctrl+W Close active window
Arrow keys Navigate desktop icons / file explorer

Project Structure

src/
  lib/
    actions/        # Svelte actions (keyboard shortcuts)
    components/     # App shell (ProjectCard, WindowManager, Taskbar)
      os/           # OS primitives (Desktop, Terminal, FileExplorer, TextEditor)
    projects/
      hacker/       # HackerOS desktop environment
    stores/         # Reactive state (windows, projects)
  routes/           # SvelteKit pages
scripts/            # Pi deployment & auto-update

Tech Stack

SvelteKit 2 / Svelte 5 / Tailwind 4 / WinBox / Motion / TypeScript

Raspberry Pi Kiosk Deployment

SetScreens runs as a dedicated kiosk on a Raspberry Pi — boot straight into a fullscreen browser, no desktop environment visible.

Hardware

Model RAM Notes
Pi 5 (4 GB) 4 GB Best performance. VideoCore VII ~2-3x GPU throughput over Pi 4.
Pi 4 (4 GB) 4 GB Recommended. Smooth GPU animations, plenty of headroom.
Pi 4 (2 GB) 2 GB Minimum viable. May spike under heavy JS/animation load.
Pi 3B+ 1 GB Works. CSS animations smooth, reduced Chromium flags for memory.

OS

Raspberry Pi OS (Bookworm, 64-bit) — Desktop or Lite both work. Desktop is easier (autologin + display server out of the box).

Deployment Options

There are two ways to get builds onto the Pi:

Method Best for How it works
rsync from dev machine Active development, immediate deploys Build locally, rsync static files over SSH
Git dist branch + auto-update Hands-off production Pi pulls pre-built files from a dist branch every 5 min

Quick Setup (rsync deploy)

This is the fastest way to get a new Pi running. No git or build tools needed on the Pi.

Prerequisites: Raspberry Pi OS installed, SSH access working.

1. From your dev machine, build and copy the bootstrap script:

bun run build
scp scripts/pi-bootstrap.sh <user>@<pi-ip>:~/

2. On the Pi, run the bootstrap:

sudo PI_USER=$(whoami) bash ~/pi-bootstrap.sh

This installs nginx, Chromium kiosk service, and cursor-hide service.

3. From your dev machine, deploy the built site:

bash scripts/deploy.sh <user>@<pi-ip>

4. Reboot the Pi:

sudo reboot

The Pi boots into fullscreen Chromium showing SetScreens. Done.

Updating: Just run bash scripts/deploy.sh <user>@<pi-ip> again — it builds, rsyncs, and refreshes the browser.

Setup with Auto-Update (git deploy)

For hands-off production use where the Pi updates itself.

1. On the Pi, clone the repo and run the full setup:

git clone <your-repo-url> ~/SetScreens
cd ~/SetScreens
sudo PI_USER=$(whoami) bash scripts/pi-setup.sh

2. From your dev machine, build and push to the dist branch.

The Pi checks the dist branch every 5 minutes and auto-deploys new builds.

What Gets Installed

Both setup scripts configure:

  • nginx — serves the static build from /var/www/setscreens on port 80
  • Chromium — kiosk mode systemd service with GPU acceleration flags
  • unclutter — hides mouse cursor after 1 second idle
  • xdotool — sends F5 to refresh browser after deploys

The pi-setup.sh script additionally installs git, Node.js, and an auto-update timer.

Scripts Reference

Script Where it runs Purpose
scripts/pi-bootstrap.sh Pi (once) Minimal kiosk setup for rsync deploys
scripts/pi-setup.sh Pi (once) Full setup including git auto-update
scripts/deploy.sh Dev machine Build + rsync + browser refresh
scripts/pi-autoupdate.sh Pi (timer) Pull dist branch and deploy if changed

Tips

  • Use a quality SD card (Samsung EVO, SanDisk Extreme) or boot from USB SSD
  • Consider overlayfs for a read-only root filesystem to survive power cuts
  • Chromium auto-restarts on crash (5-second delay via systemd)
  • Default deploy target is op@mainframe — pass a different host as the first argument to deploy.sh

Build

bun run build
bun run preview

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors