akashyadav758 Claude Opus 4.8 (1M context) commited on
Commit
b0a3b97
·
1 Parent(s): 23a7459

Wipe Chrome session-restore state on boot (stop stale tab resurrection)

Browse files

The persisted profile saves last-open tabs; on boot Chrome restored them,
resurrecting the removed Flow tab regardless of the launch URL. Delete
Sessions/ and Current/Last Tabs+Session so Chrome opens only the launch URL.
Cookies/logins are in separate files and untouched.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

Files changed (1) hide show
  1. start_hf.sh +13 -0
start_hf.sh CHANGED
@@ -67,6 +67,19 @@ echo "🔓 Removing lock files..."
67
  find /home/chrome -name "Singleton*" -exec rm -f {} +
68
  rm -f /home/chrome/data/Default/LOCK /home/chrome/data/Default/LOG.old 2>/dev/null || true
69
 
 
 
 
 
 
 
 
 
 
 
 
 
 
70
  # 4. Preferences Injection (Developer Mode & Crash Fix)
71
  python3 -c "
72
  import json, os
 
67
  find /home/chrome -name "Singleton*" -exec rm -f {} +
68
  rm -f /home/chrome/data/Default/LOCK /home/chrome/data/Default/LOG.old 2>/dev/null || true
69
 
70
+ # 3b. Session-restore wipe. The persisted profile saves the last set of open tabs
71
+ # (Sessions/, Current/Last Tabs, Current/Last Session). On boot Chrome restores
72
+ # them — which resurrects stale tabs (e.g. the removed Flow tab) regardless of the
73
+ # command-line URL. Deleting these makes Chrome open ONLY the launch URL; the
74
+ # gpt/gemini extensions then open their own service tabs. Cookies/logins live in
75
+ # separate files (Cookies, Login Data, Local Storage) and are untouched.
76
+ echo "🧹 Wiping saved session/tab restore state..."
77
+ rm -rf /home/chrome/data/Default/Sessions 2>/dev/null || true
78
+ rm -f /home/chrome/data/Default/Current\ Tabs \
79
+ /home/chrome/data/Default/Last\ Tabs \
80
+ /home/chrome/data/Default/Current\ Session \
81
+ /home/chrome/data/Default/Last\ Session 2>/dev/null || true
82
+
83
  # 4. Preferences Injection (Developer Mode & Crash Fix)
84
  python3 -c "
85
  import json, os