Mitchell Laks <ml...@post.harvard.edu> wrote: >however putting >PAGER="less -q" >alone seemed to set the variable (ie echo $PAGER >responded less -q) > >but it did not change the behavior of say "man pdl"
That’s because you only set this variable to your shell and did not export it. Observe: ->->->->->->->->->->->->->->->->->->->->->->->->->->->->->->->->-> $ D="123" $ echo $D # Echo is a shell builtin, additionally, this $D gets expanded by the calling shell 123 $ /bin/bash -c "echo $D" # Let's call a subshell and send it echo $D. $D again gets expanded by the calling (our) shell 123 $ /bin/bash -c 'echo $D' # Single quotes stop our shell from expanding variables $ export D # Export the variable D, making it available to called programs, too $ /bin/bash -c 'echo $D' # Single quotes stop our shell from expanding variables 123 -<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-< You might also want to play with the ‘env’ command, which prints out all currently-exported variables. > "/usr/pager" does not exist on my systems Good, it shouldn’t. >how would one add any alternative to the alternatives system >after creating the /bin/lessq file >(containing the line something line >less -q $1 >i guess) Just to clean that up: /bin/lessq (I would actually suggest using /usr/local/bin/lessq) would then contain something like: ->->->->->->->->->->->->->->->->->->->->->->->->->->->->->->->->-> #!/bin/sh /bin/less -q $* -<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-<-< To then install this (after making it executable) as an alternative for pager, one would have to: # update-alternatives --install /usr/bin/pager pager /usr/local/bin/lessq 100 which should automagically select /u/l/b/lessq as the default pager. If you want to change that, try # update-alternatives --config pager or, to get more information: # update-alternatives --query pager Of course, $ man update-alternatives is always a good starting point for such things. Best regards, Claudius -- Taxes are not levied for the benefit of the taxed. Please use GPG: ECB0C2C7 4A4C4046 446ADF86 C08112E5 D72CDBA4 http://chubig.net/ http://nightfall.org -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20120301180240.23b7b...@ares.home.chubig.net