main 6af0a61

dms-opt-in.sh RawHistoryFolder

1#!/bin/bash
2# dms-opt-in.sh — Optional Dank Linux full suite installation prompt
3# Runs at end of first-boot setup. Asks user if they want the full
4# Dank Linux desktop (compositor + DMS shell + terminal + all tools).
5set -euo pipefail
6
7LOG_FILE="$HOME/archup-first-boot.log"
8
9log() { echo "[dms-opt-in] $*" | tee -a "$LOG_FILE"; }
10
11FLAG_FILE="/var/lib/archup-install-danklinux"
12
13# Resolve the target user — must not run the installer as root
14INSTALL_USER="${ARCHUP_USERNAME:-}"
15if [ -z "$INSTALL_USER" ]; then
16  log "ARCHUP_USERNAME not set — skipping Dank Linux installation."
17  exit 0
18fi
19
20run_as_user() {
21  sudo -u "$INSTALL_USER" env HOME="/home/$INSTALL_USER" "$@"
22}
23
24# Auto-install if flag was set during installation
25if [ -f "$FLAG_FILE" ]; then
26  log "Dank Linux install flag detected — running installer automatically."
27  echo ""
28  echo "Installing Dank Linux (selected during system installation)..."
29  if run_as_user bash -c 'curl -fsSL https://install.danklinux.com | sh'; then
30    rm -f "$FLAG_FILE"
31    log "Dank Linux installation complete."
32  else
33    log "Dank Linux installer failed — flag preserved at $FLAG_FILE for retry."
34    exit 1
35  fi
36  exit 0
37fi
38
39# Skip if not running in an interactive terminal
40if [ ! -t 0 ]; then
41  log "Not running in interactive terminal — skipping Dank Linux opt-in."
42  exit 0
43fi
44
45# Manual prompt fallback (for reinstall / re-run scenarios)
46echo ""
47echo "=============================================="
48echo "       Dank Linux — Optional Install"
49echo "=============================================="
50echo ""
51echo "  Dank Linux is a full Wayland desktop suite:"
52echo "    - Compositor: niri or Hyprland (your choice)"
53echo "    - Shell: DankMaterialShell (Quickshell/Go)"
54echo "    - Terminal: Ghostty"
55echo "    - Auto-theming, notifications, app launcher,"
56echo "      lock screen, system tray, search — all"
57echo "      integrated. One install. Everything works."
58echo ""
59echo "  Install: curl -fsSL https://install.danklinux.com | sh"
60echo "  Note: This runs the official Dank Linux installer. Review at:"
61echo "  https://github.com/AvengeMedia/DankMaterialShell"
62echo ""
63
64read -r -p "  Do you want to run the Dank Linux installer? [y/N] " REPLY || true
65echo ""
66
67case "$REPLY" in
68  [yY][eE][sS]|[yY])
69    log "User opted in — starting Dank Linux installer."
70    echo "Starting Dank Linux installer..."
71    if run_as_user bash -c 'curl -fsSL https://install.danklinux.com | sh'; then
72      log "Dank Linux installation complete."
73    else
74      log "ERROR: Dank Linux installer failed (exit code $?)."
75      exit 1
76    fi
77    ;;
78  *)
79    log "User skipped Dank Linux installation."
80    echo "Skipping. Install later with:"
81    echo "  curl -fsSL https://install.danklinux.com | sh"
82    echo ""
83    ;;
84esac

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 1

Tags 0

    ↑↓ moveenter openesc close