Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #184911

Re: Why debian put ~/bin beginning of $PATH

From Michael Lange <klappnase@freenet.de>
Newsgroups linux.debian.user
Subject Re: Why debian put ~/bin beginning of $PATH
Date 2017-08-08 22:10 +0200
Message-ID <uciZb-5aW-1@gated-at.bofh.it> (permalink)
References <ucicO-4h6-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi,

On Wed, 9 Aug 2017 03:11:48 +0800
spp mg <sm.sppmg@gmail.com> wrote:

> Hi all
> 
> In the ~/.profile has below default setting:
> 
> --------------
> # set PATH so it includes user's private bin if it exists
> if [ -d "$HOME/bin" ] ; then
>     PATH="$HOME/bin:$PATH"
> fi
> --------------
> 
> Why put ~/bin beginning ? Is that dangerous ?

like other people already pointed out there shouldn't be anything
dangerous about this.
One possible use case is for example that you could put there a
minimal script that temporarily overrides some environment variable, like
one I have here which reads:

#!/bin/bash
GTK_IM_MODULE=gtk /usr/bin/poedit $@
exit $?

This way I can conveniently call "poedit <filename>" with the desired
setting of GTK_IM_MODULE without either having to type the whole thing
each time or else having to permanently change GTK_IM_MODULE's setting
(the default value of which I modified for other reasons).

Best regards

Michael

.-.. .. ...- .   .-.. --- -. --.   .- -. -..   .--. .-. --- ... .--. . .-.

Fascinating, a totally parochial attitude.
		-- Spock, "Metamorphosis", stardate 3219.8

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Why debian put ~/bin beginning of $PATH spp mg <sm.sppmg@gmail.com> - 2017-08-08 21:20 +0200
  Re: Why debian put ~/bin beginning of $PATH Nicolas George <george@nsup.org> - 2017-08-08 21:40 +0200
  Re: Why debian put ~/bin beginning of $PATH John Elliot V <jj5@jj5.net> - 2017-08-08 21:40 +0200
  Re: Why debian put ~/bin beginning of $PATH Michael Lange <klappnase@freenet.de> - 2017-08-08 22:10 +0200
    Re: Why debian put ~/bin beginning of $PATH spp mg <sm.sppmg@gmail.com> - 2017-08-08 23:00 +0200
      Re: Why debian put ~/bin beginning of $PATH Michael Lange <klappnase@freenet.de> - 2017-08-08 23:30 +0200
      Re: Why debian put ~/bin beginning of $PATH Teemu Likonen <tlikonen@iki.fi> - 2017-08-09 06:50 +0200
        Re: Why debian put ~/bin beginning of $PATH Teemu Likonen <tlikonen@iki.fi> - 2017-08-09 07:00 +0200
      Re: Why debian put ~/bin beginning of $PATH "Gian Uberto Lauri" <saint@eng.it> - 2017-08-09 18:20 +0200
        Re: Why debian put ~/bin beginning of $PATH David Wright <deblis@lionunicorn.co.uk> - 2017-08-09 19:00 +0200
    Re: Why debian put ~/bin beginning of $PATH Greg Wooledge <wooledg@eeg.ccf.org> - 2017-08-09 15:20 +0200
  Re: Why debian put ~/bin beginning of $PATH soyeomul@doraji.xyz (Byung-Hee HWANG (황병희, 黃炳熙)) - 2017-08-11 16:00 +0200
  Re: Why debian put ~/bin beginning of $PATH Vincent Lefevre <vincent@vinc17.net> - 2017-08-14 15:30 +0200

csiph-web