aboutsummaryrefslogtreecommitdiffstats
path: root/glide
diff options
context:
space:
mode:
authorGravatar Tom Willemse2026-06-03 16:43:59 -0700
committerGravatar Tom Willemse2026-06-03 16:45:52 -0700
commit8209b38364ef60ed3293142d680a47b0a1a5ce58 (patch)
tree80b4da855c00c99be5403cf081d526800e3dafdd /glide
parent64f820dfb11c8c60fdc625d2b2740f4e9c8f8eae (diff)
downloadnew-dotfiles-8209b38364ef60ed3293142d680a47b0a1a5ce58.tar.gz
new-dotfiles-8209b38364ef60ed3293142d680a47b0a1a5ce58.zip
glide: Fix adding new groups
If there are no groups at all, then the execute method is never added to any option and will never run. Add a dummy group just in case.
Diffstat (limited to 'glide')
-rw-r--r--glide/.config/glide/glide.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/glide/.config/glide/glide.ts b/glide/.config/glide/glide.ts
index 6bad42c..af5d1bf 100644
--- a/glide/.config/glide/glide.ts
+++ b/glide/.config/glide/glide.ts
@@ -377,7 +377,12 @@ const group_tab = glide.excmds.create({
name: 'group_tab',
description: 'Add the current tab to a group.'
}, async ({ tab_id }) => {
- const groups = await browser.tabGroups.query({});
+ let groups = await browser.tabGroups.query({});
+
+ if (groups.length === 0) {
+ groups = [{title: ''}];
+ }
+
glide.commandline.show({
title: "group",
options: groups.map((group) => ({