Marc Cornellà
a87e9c715b
fix(init): fix definition order for `$ZSH_CUSTOM`
...
Tipped about this in https://github.com/ohmyzsh/ohmyzsh/commit/6754b7e67#commitcomment-143280115
2 years ago
Mayu Laierlence
6754b7e67b
feat(init): add custom functions and completions to `$fpath` ( #5644 )
...
Closes #5644
Co-authored-by: Marc Cornellà <marc@mcornella.com>
2 years ago
vladislav doster
1d09c6bb0a
style: remove trailing whitespace ( #12303 )
2 years ago
Marc Cornellà
30f0d59188
fix(init): exit gracefully if on non-zsh emulation mode ( #11874 )
...
Fixes #11686
3 years ago
LuckyWindsck
dfe2f04de7
refactor(init): rename variable ( #11851 )
3 years ago
Carlo Sala
b22593cf17
fix(init): avoid overwriting existing aliases
...
Fix regression introduced in #11550 . If an existing alias was present in
the moment of sourcing, and oh-my-zsh aliases were disabled for that
file, it'd be overwritten aswell. See #11658 .
3 years ago
Marc Cornellà
9233ef75f2
fix(init): don't use digits in parameter modifiers for compatibility ( #11598 )
...
Digit modifiers were introduced in zsh 5.7.1 [1]. This commit uses readily available
alternatives for backwards compatibility.
[1] https://github.com/zsh-users/zsh/commit/b8dc5a7f6d
Fixes #11598
3 years ago
Marc Cornellà
1ad167dfac
feat(init)!: allow turning off aliases for libs and plugins ( #11550 )
...
BREAKING CHANGE: the previous zstyle setting to disable `lib/directories.zsh` aliases has
been changed to the new syntax: `zstyle ':omz:lib:directories' aliases no`. See
https://github.com/ohmyzsh/ohmyzsh#skip-aliases to see other ways you can use this setting.
Co-authored-by: Carlo Sala <carlosalag@protonmail.com>
3 years ago
Marc Cornellà
d342b353e3
fix(init): set completion colors on theme load, not with `precmd`
...
This fixes an edge case where the user actually sets
zstyle ':completion:*' list-colors
in their zshrc, but the previous code used a precmd hook, which would
override the user changes. With this change our modifications will be
set in the init script, after the theme loads, so that later changes
can affect our defaults.
Note that this will not be run for users on plugin managers, as these
don't generally run our init script.
3 years ago
Carlo Sala
5b9de6a530
fix(init): remove duplicated check
...
It was added due to #9039 . See https://github.com/ohmyzsh/ohmyzsh/pull/11400#pullrequestreview-1223587420
4 years ago
Carlo
d93f317450
fix(init): prevent multiple compdump compilations ( #11345 )
...
Closes #11341
4 years ago
Giovanni Squillero
7dcabbe682
chore(init): ignore any aliases when running `rm` ( #11156 )
4 years ago
Monson Shao
875a455320
perf: `zrecompile` the compdump file to speed up startup ( #8802 )
4 years ago
Carlo Sala
a26d72baa2
fix(init): check for unsafe directories in `fpath` ( #10672 )
4 years ago
Carlo Sala
eabec36586
style(init): use consistent code style in init script ( #10601 )
5 years ago
Marc Cornellà
a54148a43e
fix(init): rename function `f` due to clash with `f` alias ( #10260 )
...
Fixes #10260
5 years ago
Marc Cornellà
7152a94280
feat(init): show error and process tree if OMZ is loaded from non-zsh shells ( #10234 )
5 years ago
Marc Cornellà
33c86fe80b
fix(init): detect and abort on non-zsh shell execution of Oh My Zsh
5 years ago
Marc Cornellà
2ea1fa6cbf
fix(init): fix `division by 0` error ( #10213 )
...
Fixes #10213
5 years ago
Marc Cornellà
93b557e291
style(core): make alternative cache directory equivalent to Arch Linux package
...
The oh-my-zsh-git package sets the cache directory to `$HOME/.cache/oh-my-zsh`, so
Oh My Zsh will be compatible with it.
5 years ago
Marc Cornellà
8784e88552
fix(core): use `$HOME/.cache` if default cache dir is non-writable ( #10193 )
...
Fixes #10193
5 years ago
Marc Cornellà
d2269180b0
fix(core): move plugin-generated completion files to `$ZSH_CACHE_DIR/completions`
...
Fixes #10183
5 years ago
Marc Cornellà
28ee5846bb
init: define $ZSH if not defined
...
Closes #9223
6 years ago
Ye Shu
5ffc0d036c
init: don't run update check if DISABLE_AUTO_UPDATE ( #9040 )
...
skip the update check at initialization if DISABLE_AUTO_UPDATE is set to true
6 years ago
Marc Cornellà
3f6e87df15
init: run update check in the same zsh process ( #9019 )
6 years ago
Marc Cornellà
3c777ebf1b
update: refactor and fix logic in check_for_upgrade.sh ( #8939 )
6 years ago
Marc Cornellà
aee9e603b4
init: reapply hack for invalid ZSH_COMPDUMP filenames ( b8761985)
6 years ago
Marc Cornellà
c58572d5fe
init: oops
6 years ago
Marc Cornellà
0e12ebb42d
init: use grep for zcompdump metadata check
...
Closes #8981
6 years ago
Jacob Menke
582c8cb291
Prefix cd calls with `builtin` ( #8937 )
6 years ago
Marc Cornellà
b876198575
init: silence zcompdump metadata write for invalid ZSH_COMPDUMP filenames
...
If `$SHORT_HOST` contains invalid filename characters, the compinit call doesn't
error, but the zcompdump metadata write does. Use `tee` instead so we can silence
the error.
See dd1a72696f (commitcomment-38984764)
6 years ago
Marc Cornellà
ff987384cf
core: fix cmp invocation in BSD systems
...
BSD cmp doesn't have the option of reading from stdin, so use process
substitution instead.
6 years ago
Marc Cornellà
dd1a72696f
core: refresh zcompdump cache file in init script ( #8878 )
6 years ago
Marc Cornellà
173d4ca68f
core: move core folder to lib, for now
6 years ago
Marc Cornellà
07bcf041c0
core: add basic Oh My Zsh CLI ( #8876 )
6 years ago
Willy Weiskopf
6adad5c300
Move random theme functionality into "random" theme
...
The statements for selecting a random theme in oh-my-zsh.sh and the themes
plugin are duplicate. Most people eventually settle on a theme, making those
lines in oh-my-zsh.sh superfluous. To address those, it may makes sense to put
the random theme functionality into a theme of its own (since themes are just
zsh scripts.
6 years ago
Marc Cornellà
a04728f168
init: force use of builtin test in is_plugin
...
Fixes #8545
7 years ago
Marc Cornellà
ea3e666e04
init: run compinit before loading lib/ files
7 years ago
Greg
3a6bf6bd26
init: more informative warning if plugin not found ( #7727 )
7 years ago
Avi ד
1e11a3c112
init: fix erroneous plugin not found warning ( #7686 )
...
Co-authored-by: Se De <Sede7473@gmail.com>
7 years ago
SomeDer
779ff24c2d
init: notify user if plugin isn't found ( #7679 )
7 years ago
Marc Cornellà
4cdffcd485
init: cut down on the number of compaudit calls
7 years ago
Chao Du
e96a7b728a
migrate .zsh-update file
8 years ago
Chao Du
de8299d6c4
Fixed Issue #4550 : Move ~/.zsh-update file to $ZSH_CACHE_DIR
8 years ago
Marc Cornellà
b91659951e
Always load secure completion directories
8 years ago
Marc Cornellà
afba4f6b9f
Load insecure completion files if compfix is disabled
...
We have to assume that if people disabled the compfix system they really want
their completion to work, ignoring any permission issues.
Fixes #5651
Fixes #5957
Fixes #6461
8 years ago
Mason
f94d4e6a40
Change from OSX to macOS in README ( #5545 )
10 years ago
Marc Cornellà
d8b03f3f95
init script: remove trailing slash from $ZSH_CACHE_DIR
10 years ago
LE Manh Cuong
5e77e00ad5
Some improvements
...
- Adding documentation
- Note the effect empty array
- Fix spelling
- Using new test `[[...]]`
11 years ago
LE Manh Cuong
531c41cdfe
Allow loading themes from predefined list
11 years ago