SlickEdit Product Discussion > SlickEdit®

System commands help is displayed instead of functions help in Linux?



Is there a way to make SE to show a man of a function, instead of a system command (when there is one with the same name)? For example, trying to show the help for the stat() function brings the stat command, and not the function description.

I think it's because the stat command man page is higher in priority then the function man page, but this only a guess.



--- Quote from: SyRenity on July 06, 2006, 07:40:07 pm ---Hi.

Is there a way to make SE to show a man of a function, instead of a system command (when there is one with the same name)?

--- End quote ---

You might want to give the section number to the command, like this

--- Code: ---man 2 stat
--- End code ---

This should display the system call stat, instead of the user command version.


Thanks for the tip. Is there a way to make SE to show the correct man pages?

Since SlickEdit simply executes the system "man" command and displays its output, what you need do is to change the section search order that your man command follows.  You could control the section search order at several different levels.  To do it globally, become a super user and edit /etc/man.config.  Find the parameter named MANSECT.  Its value should look like 1:8:2:3:4:5:6:7:9:0p:1p:3p:tcl:n:l:p:o .  Simply move the 2 before the 1, and save the file.  This way section 2 is always searched before section 1, and in the case of the stat command, you would always get the stat system call, not the stat shell command.  This also applies when you execute the man command within SlickEdit.

If you don't want the change to be global or you don't have a super user account on your system, you can set the MANSECT environment variable to something like 2:1:8:3:4:5:6:7:9:0p:1p:3p:tcl:n:l:p:o by

--- Code: ---export MANSECT=2:1:8:3:4:5:6:7:9:0p:1p:3p:tcl:n:l:p:o
--- End code ---
then the change is limited only to the current session.

If you even want to limit the change to a certain workspace within SlickEdit, go to Project > Workspace Properties > Environment, and set the MANSECT value therein.  This way, the change only affects that specific workspace.

Thank you for the explanation. Eventually I started using the command line "man X function_name", because some of the functions are located on the 3 index.


[0] Message Index

Go to full version