tangled
alpha
login
or
join now
hyperreal.bsky.moonshadow.dev
/
bin
0
fork
atom
Assorted shell and Python scripts
0
fork
atom
overview
issues
pulls
pipelines
~split_man.sh
hyperreal.bsky.moonshadow.dev
2 months ago
ccb433f1
0546ec9b
+3
-64
3 changed files
expand all
collapse all
unified
split
.zed
settings.json
split_dict.sh
split_man.sh
-33
.zed/settings.json
···
1
1
{
2
2
"show_edit_predictions": false,
3
3
-
"file_types": {
4
4
-
"Bash": [
5
5
-
"amimullvad",
6
6
-
"archivebox_schedule",
7
7
-
"awkuptime",
8
8
-
"backup_podvol",
9
9
-
"bluebuild_iso",
10
10
-
"encrypt_mail",
11
11
-
"gumssh",
12
12
-
"moonshadow_openbsd_backup",
13
13
-
"natpmpcd",
14
14
-
"quickinfo",
15
15
-
"split_dict",
16
16
-
"split_man",
17
17
-
"swivel",
18
18
-
"sync_files",
19
19
-
"systemd_syscall_filter",
20
20
-
],
21
21
-
"Perl": ["check_wg_handshake", "feed_count.raku"],
22
22
-
"Python": [
23
23
-
"blog2gemlog",
24
24
-
"dl-wp-pdf",
25
25
-
"fetch_combined_trackers_list",
26
26
-
"get-def",
27
27
-
"list_torrents",
28
28
-
"print-wp-sources",
29
29
-
"pyuptime",
30
30
-
"qbt_helper",
31
31
-
"qbt_sum_size",
32
32
-
"scihub_knapsack",
33
33
-
"seed_armbian_torrents",
34
34
-
],
35
35
-
},
36
3
}
-24
split_dict.sh
···
1
1
-
#!/usr/bin/env bash
2
2
-
3
3
-
# Check if gum is available
4
4
-
if ! command -v gum >/dev/null; then
5
5
-
echo "Missing dependency: gum"
6
6
-
echo "See https://github.com/charmbracelet/gum"
7
7
-
exit 1
8
8
-
fi
9
9
-
10
10
-
# Check if get-def is available
11
11
-
if ! command -v get-def >/dev/null; then
12
12
-
echo "Missing dependency: get-def"
13
13
-
echo "Run pipx install get-def"
14
14
-
exit 1
15
15
-
fi
16
16
-
17
17
-
WORD=$(gum input --placeholder="word")
18
18
-
19
19
-
if [[ -n "$ZELLIJ" ]]; then
20
20
-
zellij action new-pane -- get-def "$WORD"
21
21
-
else
22
22
-
echo "No Zellij sessions detected."
23
23
-
exit 1
24
24
-
fi
+3
-7
split_man.sh
···
9
9
10
10
CMD=$(gum input --placeholder="command")
11
11
12
12
-
if [[ -n "$BYOBU_BACKEND" && "$BYOBU_BACKEND" = "tmux" ]]; then
13
13
-
byobu-tmux split-window -h man "$CMD"
14
14
-
elif [[ -n "$TMUX" ]]; then
15
15
-
tmux split-window -h man "$CMD"
16
16
-
elif [[ -n "$ZELLIJ" ]]; then
17
17
-
zellij action new-pane -- man "$CMD"
12
12
+
if [[ -n "$ZELLIJ" ]]; then
13
13
+
zellij action new-pane -c -f --height 38 --width 150 -x 50 -y 3 -- batman "$CMD"
18
14
else
19
19
-
echo "No byobu, tmux, or Zellij sessions detected"
15
15
+
echo "No Zellij sessions detected"
20
16
exit 1
21
17
fi