From: ng0@n0.is
To: 30265@debbugs.gnu.org
Subject: bug#30265: Fish shell has wrong path variables
Date: Sat, 27 Jan 2018 10:36:42 +0000 [thread overview]
Message-ID: <87shar8u6d.fsf@abyayala.i-did-not-set--mail-host-address--so-tickle-me> (raw)
In-Reply-To: <87inbnpsx9.fsf@gmail.com> (Meiyo Peng's message of "Sat, 27 Jan 2018 17:11:46 +0800")
Hi Meiyo,
thanks for your report. Indeed, Fish has some problems in Guix.
On Sat, 27 Jan 2018, Meiyo Peng <meiyo.peng@gmail.com> wrote:
> Hi,
>
> I am using GuixSD 0.14. After upgrading fish shell to latest version(v2.7.1) and
> running `guix gc`, fish shell does not work well.
Can you explain a bit more about your setup? I assume you use
fish as you user shell and not just as a shell you switch into
from a Bash enabled user, correct?
> #+BEGIN_EXAMPLE
> meiyo@guix ~$ fish
> fish:
> echo $_ " "; __fish_pwd
> ^
> in command substitution
> called on standard input
>
> fish:
> __fish_pwd
> ^
> in command substitution
> called on standard input
>
> in command substitution
> called on standard input
>
> fish:
> echo $_ " "; __fish_pwd
> ^
> in command substitution
> called on standard input
> #+END_EXAMPLE
>
>
> __fish_pwd is a fish function. It's defined in
> `share/fish/functions/__fish_pwd.fish`. The error message shows that fish
> cannot load __fish_pwd's function definition from disk. After doing some
> research, I found out that the error was caused by wrong environment variables.
>
> Fish shell is installed in:
>
> #+BEGIN_EXAMPLE
> /gnu/store/ajbbi9cgj9j0my7v5habp0lcysaf2a51-fish-2.7.1/
> #+END_EXAMPLE
>
>
> But the environment variable $fish_function_path does not exist. And these
> environment variables point to non-existent paths:
>
> #+BEGIN_EXAMPLE
> __fish_bin_dir /gnu/store/4jkxcz8kpy621ycmqn3rvs0fv6c98h6p-fish-2.7.1/bin
> __fish_datadir /gnu/store/4jkxcz8kpy621ycmqn3rvs0fv6c98h6p-fish-2.7.1/share/fish
> #+END_EXAMPLE
>
>
> Setting $fish_function_path to the correct path reduces the error message.
>
> #+BEGIN_EXAMPLE
> set fish_function_path /gnu/store/ajbbi9cgj9j0my7v5habp0lcysaf2a51-fish-2.7.1/share/fish/functions
> #+END_EXAMPLE
>
>
> `share/fish/config.fish` states $__fish_datadir is set by fish.cpp,
> and $fish_function_path is derived from $__fish_datadir.
>
> #+BEGIN_SRC fish
> # __fish_datadir, __fish_sysconfdir, __fish_help_dir, __fish_bin_dir
> # are expected to have been set up by read_init from fish.cpp
>
>
> # Set up function and completion paths. Make sure that the fish
> # default functions/completions are included in the respective path.
>
> if not set -q fish_function_path
> set fish_function_path $configdir/fish/functions $__fish_sysconfdir/functions $__extra_functionsdir $__fish_datadir/functions
> end
>
> if not contains -- $__fish_datadir/functions $fish_function_path
> set fish_function_path $fish_function_path $__fish_datadir/functions
> end
> #+END_SRC
>
> In conclusion, I think some path related variables are not set correctly when
> fish is compiled from source code and that caused the bug I met. But since I'm
> not good at C++ programming, I will not dive deeper.
>
> I hope that the information provided above is helpful.
>
>
> Meiyo Peng
It's more or less known, I assume this is related to bug#27206
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=27206
Which to my knowledge and sources I've read doesn't require C
knowledge but more knowledge of how Fish interacts on
system/vendor level and some testing with the resources I've
provided in the other thread/bug.
--
ng0 :: https://ea.n0.is
A88C8ADD129828D7EAC02E52E22F9BBFEE348588 :: https://ea.n0.is/keys/
next prev parent reply other threads:[~2018-01-27 10:37 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-27 9:11 bug#30265: Fish shell has wrong path variables Meiyo Peng
2018-01-27 10:36 ` ng0 [this message]
2018-01-27 16:25 ` Ludovic Courtès
2018-01-27 18:19 ` ng0
2018-01-27 12:19 ` Ricardo Wurmus
2018-01-27 13:45 ` Meiyo Peng
2018-01-27 14:13 ` Meiyo Peng
2018-09-19 9:09 ` Pierre Neidhardt
2018-09-19 20:39 ` Ludovic Courtès
2018-09-20 16:09 ` Pierre Neidhardt
2018-09-20 17:00 ` Ricardo Wurmus
2018-09-20 17:12 ` Pierre Neidhardt
2018-09-21 12:03 ` Ludovic Courtès
2018-09-21 12:05 ` Ludovic Courtès
2018-09-21 14:42 ` Pierre Neidhardt
2018-09-21 14:46 ` Ricardo Wurmus
2018-09-21 15:11 ` Pierre Neidhardt
2019-02-02 7:20 ` bug#30265: Fish embeds store file names in UCS-4/UTF-32 literal strings Meiyo Peng
2019-02-04 22:16 ` Ludovic Courtès
2020-03-30 6:29 ` John Soo
2022-10-07 19:42 ` Maxim Cournoyer
2022-10-07 19:43 ` Maxim Cournoyer
2022-10-07 19:44 ` John Soo
2022-10-07 20:57 ` Mark H Weaver
2022-10-10 3:38 ` Maxim Cournoyer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87shar8u6d.fsf@abyayala.i-did-not-set--mail-host-address--so-tickle-me \
--to=ng0@n0.is \
--cc=30265@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).