Skip to content

fix busybox compatibility#137

Open
mjholub wants to merge 1 commit into
franciscolourenco:masterfrom
mjholub:busybox-patch
Open

fix busybox compatibility#137
mjholub wants to merge 1 commit into
franciscolourenco:masterfrom
mjholub:busybox-patch

Conversation

@mjholub
Copy link
Copy Markdown

@mjholub mjholub commented May 28, 2023

albeit this approach is more verbose, this allowed me to use this plugin under Alpine and shouldn't break coreutils systems either

Signed-off-by: Marcelina Hołub <mholub@tutanota.com>

fix: awk busybox compat

Signed-off-by: Marcelina Hołub <mholub@tutanota.com>
Comment thread conf.d/done.fish
# awk is used instead of ps with -o ppid= because the latter is not
# supported by busybox
set tmux_fish_ppid (awk '/PPid:/ {print $2}' /proc/$tmux_fish_pid/status)
set tmux_fish_ppid_cmd_full (busybox ps | awk "{if (\$1 == $tmux_fish_ppid) print \$NF}")
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@154pinkchairs you are using busybox in this line, but as far as I understand it is not available in every system. What's the idea?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm yup, my idea was just to have the script work with both, must've missed it

Copy link
Copy Markdown
Owner

@franciscolourenco franciscolourenco Sep 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you like to work on alternative? The existing function is error prone and I will have to choose one of the proposed options. This doesn't sound bad if it also covers the other edge cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants