aboutsummaryrefslogtreecommitdiff
path: root/sh/profile
Commit message (Collapse)AuthorAgeFilesLines
* Fix a zsh-as-sh/ksh-specific issueTom Ryder2016-12-301-0/+8
| | | | Very niche, but interesting to fix anyway
* Change tack; force ENV if the file existsTom Ryder2016-12-181-2/+2
|
* Split ~/.shrc off stub ~/.shinit fileTom Ryder2016-12-031-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | NetBSD sh(1) and possible others don't tolerate a `return` short-circuit for ENV, which means that because that implementation also sources ENV if set regardless of whether the shell is interactive or not, all of the interactive stuff in ~/.shrc and ~/.shrc.d gets uselessly sourced and loaded up for non-interactive invocations of sh(1). To work around this, I've set ENV to be a new ~/.shinit file instead, which sources the ~/.shrc file only if the shell is interactive. ~/.shinit is the filename suggested in the man page for NetBSD sh(1) and Debian dash(1) as well. NetBSD's documented behaviour seems to be contrary to POSIX 2003: > ENV: This variable, when and only when an interactive shell is > invoked, shall be subjected to parameter expansion (see Parameter > Expansion ) by the shell, and the resulting value shall be used as a > pathname of a file containing shell commands to execute in the > current environment. No matter; this works fine, and makes non-interactive invocations of sh(1) on NetBSD much faster.
* Use terser syntax for path additionTom Ryder2016-09-011-3/+1
|
* Remove OLDPWD hackTom Ryder2016-08-201-22/+0
| | | | It doesn't really make sense anyway
* Move oldpwd.sh functionality into profileTom Ryder2016-08-201-5/+11
|
* Port all bash_profile.d scripts to POSIX shTom Ryder2016-08-201-0/+1
| | | | | Also require flag files in ~/.welcome for displaying or not displaying login stuff
* Move OLDPWD setting to POSIX sh dirTom Ryder2016-08-201-0/+15
| | | | With an attempt at correct trapping; may still require tweaking
* Use consistent syntax for sh source loopsTom Ryder2016-08-181-4/+3
|
* Handle setting ENV from ~/.profileTom Ryder2016-08-171-3/+4
|
* Move interactive tests back into *rc filesTom Ryder2016-08-171-4/+4
| | | | | | I don't fully understand why I have to do it this way yet, but if I don't, calling SSH with a command raises "stdin: not a terminal" because ~/.bashrc was called.
* Move simple Bash/pdksh functions into POSIX shTom Ryder2016-08-171-0/+5
| | | | | | | Have only translated the scripts that translate readily into POSIX sh for now. More complex stuff like that bd/pd/sd/ud navigation for Bash doesn't port as easily, mostly because there isn't an analogue for the "local" keyword in POSIX.
* Use terser syntax for .d loop sourcesTom Ryder2016-07-301-8/+5
|
* Remove blank lines at end of filesTom Ryder2016-03-281-1/+0
|
* Check existence of subfilesTom Ryder2015-06-071-1/+3
|
* Don't clobber $_ (changed my mind)Tom Ryder2015-05-311-2/+3
|
* Use $_ for source parts topic varTom Ryder2015-05-181-3/+2
|
* Move unset in run-parts bashrc/profile sourceTom Ryder2015-05-151-1/+1
|
* Raise error message if .d sh file can't be readTom Ryder2015-01-291-3/+1
|
* Remove some unneeded quotesTom Ryder2014-10-161-1/+1
| | | | God bless you, shellcheck(1)
* Remove redundant export call for PATHTom Ryder2014-04-281-1/+0
|
* Use space before semicolon as command separatorTom Ryder2014-02-101-4/+4
|
* Use explicit if for conditionTom Ryder2014-02-101-1/+3
| | | | Clearer than &&
* Explicitly check extension of .d filesTom Ryder2014-02-101-1/+1
|
* Use -r test consistently rather than -fTom Ryder2014-02-101-1/+1
| | | | Implicitly check whether file exists and is legible
* Explicitly unset variables in profileTom Ryder2013-09-151-1/+1
|
* Break editor/pager setup into subfileTom Ryder2013-09-151-9/+0
|
* Tidier quoting for PATH logicTom Ryder2013-09-151-1/+1
|
* Handle empty .bashrc.d/.profile.d dirsTom Ryder2013-09-021-1/+1
|
* Better var names for subfile config sourcingTom Ryder2013-08-201-3/+3
|
* Fix a few variable contamination issuesTom Ryder2013-08-201-0/+1
|
* More conservative expansion for dotfile pathsTom Ryder2013-08-201-3/+3
|
* Remove unnecessary quoting in simple assignmentsTom Ryder2013-08-201-1/+1
|
* More thorough quotingTom Ryder2013-08-051-2/+2
|
* Improve comments on shell scriptsTom Ryder2013-07-311-2/+2
|
* Keep export calls separate from definitionsTom Ryder2013-07-311-3/+5
|
* Use standard structure for if/for in shellTom Ryder2013-07-311-5/+5
| | | | | | | | | | | | | | | | | | | Mostly for clarity reasons; using this syntax: if [ condition ]; then commands fi As opposed to: if [ condition ] then commands fi Or: [ condition ] && command
* Tidier layout, start using .bash_profile againTom Ryder2013-07-121-3/+0
| | | | Shouldn't refer to Bash stuff in Bourne shell profile
* Nice syntax for ANDTom Ryder2013-06-251-1/+1
|
* Remove Bashism from Bourne shell profileTom Ryder2013-06-241-1/+1
|
* Massive overhaul of structure for Bash filesTom Ryder2013-06-201-0/+23
* No longer using .bash_logout * No longer using .bash_profile, using POSIX-compliant .profile * instead; in particular, moved most of environment settings into .profile * Moved some of the separable functionality of both .profile and .bashrc into subdirectories (some scripts shared, some not) * Tidied implementation of ls/grep aliases * Updated install script to reflect all of the above