Skip to content

MANPATH, colon as prefix #935

Closed
Closed

Description

@afics

Snippet of manpath's manpage:

ENVIRONMENT
       MANPATH
              If  $MANPATH is set, manpath displays its value rather than determin‐
              ing it on the fly.  If $MANPATH is prefixed  by  a  colon,  then  the
              value  of  the  variable  is appended to the list determined from the
              content of the configuration files.  If the colon comes at the end of
              the  value  in  the variable, then the determined list is appended to
              the content of the variable.  If the value of the variable contains a
              double colon (::), then the determined list is inserted in the middle
              of the value, between the two colons.

I have problems with the second sentence because I don't see a way to prefix $MANPATH with a colon since fish uses space as seperator. Is there a way to accomplish this?

Activity

  1. zanchey commented on Jul 28, 2013

    @zanchey
    Member

    You can prefix it without too much trouble:

    $ set -gx MANPATH :/home/zanchey/man /home/someone/man
    $ manpath
    manpath: warning: $MANPATH set, inserting /etc/manpath.config
    /usr/local/man:/usr/local/share/man:/usr/share/man:/home/zanchey/man:/home/someone/man

    Inserting the double-colon gets a bit more exciting:

    $ set -gx MANPATH /home/zanchey: /var/bla
    $ manpath
    manpath: warning: $MANPATH set, inserting /etc/manpath.config
    /home/zanchey:/usr/local/man:/usr/local/share/man:/usr/share/man:/var/bla
  2. sugar700 commented on Jul 28, 2013

    @sugar700
    Contributor

    Or you can put empty entry.

    $ set -gx MANPATH "" /home/zanchey/man /home/someone/man
    
  3. afics commented on Jul 29, 2013

    @afics
    Author

    Thank you, I already tried both of them but nullified my changes later because I overlooked some lines in my config.

  4. added a commit that references this issue on Nov 26, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions