1 |
Peter Humphrey <peter@××××××××××××.uk> wrote: |
2 |
> |
3 |
>> Dropping the aliases into ~/.zshrc is the easy option, that way to get |
4 |
>> your aliases and a superior shell. |
5 |
> |
6 |
> That's what I've done so far. |
7 |
|
8 |
If you have a complex bash configuration file which you want to keep, |
9 |
source your .bashrc (or whatever you use) in compatibility mode |
10 |
(the anonymous function will keep that mode local only for sourcing): |
11 |
|
12 |
() { |
13 |
emulate -L sh |
14 |
setopt kshglob noshglob braceexpand nonomatch |
15 |
. ~/.bashrc |
16 |
} |
17 |
|
18 |
Most setups should work without any issues in this compatibility |
19 |
mode, the most notable exception being [[ $var ]] which must be |
20 |
cast into the more compatible [[ -n $var ]]. |