@ -1,2 +1,24 @@ | |||
# expand-user-path | |||
# Expand user's PATH | |||
- Expands `PATH` variable for each user; Adds user-specific `$HOME/.local/bin` to `PATH`. | |||
## Installation | |||
``` | |||
git clone https://fjordtek.com/git/Fincer/expand-user-path | |||
``` | |||
**NOTE**: You need to re-login into your shell to see changes. | |||
### Manually | |||
Place [user-path.sh](files/user-path.sh) into `/etc/profile.d/` folder. | |||
### Arch Linux | |||
Get [PKGBUILD](files/PKGBUILD) and [user-path.sh](files/user-path.sh). Run `updpkgsums && makepkg -i`. | |||
## License | |||
See [LICENSE](LICENSE). |
@ -0,0 +1,17 @@ | |||
pkgname=expand-user-path | |||
pkgver=1 | |||
pkgrel=1 | |||
pkgdesc='Expand PATH variable. Set user-wide PATH $HOME/.local/bin for each user' | |||
arch=('any') | |||
url='https://fjordtek.com/git/Fincer/expand-user-path' | |||
license=('GPL') | |||
depends=() | |||
makedepends=() | |||
source=( | |||
'user-path.sh' | |||
) | |||
md5sums=('267d50bda049aadfa942e8329e114bae') | |||
package() { | |||
install -Dm 644 -t "$pkgdir/etc/profile.d/" *.sh | |||
} |
@ -0,0 +1,18 @@ | |||
# Copyright © 2020 Pekka Helenius <fincer89@hotmail.com> | |||
# This program is free software: you can redistribute it and/or modify | |||
# it under the terms of the GNU General Public License as published by | |||
# the Free Software Foundation, either version 3 of the License, or | |||
# (at your option) any later version. | |||
# | |||
# This program is distributed in the hope that it will be useful, | |||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | |||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |||
# GNU General Public License for more details. | |||
# | |||
# You should have received a copy of the GNU General Public License | |||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
# Not home? | |||
[ -n "$HOME" ] || return 0 | |||
export PATH="$HOME/.local/bin:$PATH" |