Alexander Barton [Sat, 10 Feb 2024 16:35:48 +0000 (17:35 +0100)]
Don't initialize Powerlevel10k "instant prompt" too early
A non-login shell which is not a (direct) sub-shells of an AX-ZSH
enabled shell will "catch up" on the "ax-io" and "zprofile" stages, so
don't initialize the Powerlevel10k "instant prompt" too early, before
catching up on the "ax-io" stage!
Alexander Barton [Wed, 17 Jan 2024 09:48:52 +0000 (10:48 +0100)]
std_functions: Enhance take(), introduce untake()
take() now creates an new temporary directory when called without
parameters (and changes the working directory into it).
The new untake() functions changes the current working directory to the
home directory and recursively deletes the old working directory when
the path matches a pattern which is used for temporary directorues
created by take().
30_env: Make sure the default environment is always set
Now the default environment is set up in non-login shells by including
the "30_env.ax-io" code, too, if some of the standard variables are not
set or invalid.
Alexander Barton [Tue, 20 Jun 2023 15:26:47 +0000 (17:26 +0200)]
30_path: No longer look for Homebrew
Use the "homebrew" plugin instead, which will setup the environment
itself -- and setting the PATH here effectively prevents the plugin from
doing it properly (because "brew shellenv" will become a no-op)!
Alexander Barton [Tue, 20 Jun 2023 15:24:22 +0000 (17:24 +0200)]
homebrew: No longer provide a "brew" wrapper function
Don't provide a "brew" wrapper shell function (which was not available
for other commands), look for the "real" brew command instead and use it
with the "shellenv" subcommand to properly setup the environment.
Alexander Barton [Sun, 11 Dec 2022 14:36:25 +0000 (15:36 +0100)]
Look for configuration files in $ZDOTDIR
This allows you to set/override the ZDOTDIR environment variable in your
~/.zshenv file to have different "sets" of AX-ZSH configurations in
different ZDOTDIR folders. For example, for different terminal emulator
applications, system architectures or hosts.
If ZDOTDIR is not set, $HOME is used (so no functional changes when the
ZDOTDIR environment variable is not set).
Alexander Barton [Sat, 27 Aug 2022 15:41:11 +0000 (17:41 +0200)]
homebrew: Add a wrapper function for the brew(1) command
This wrapper function for the `brew`(1) command does the following:
- Detect the location of the "real" brew(1) command.
- Change user and group when the Homebrew installation is owned by a different
user (to preserve sane file permissions).
- Set a relaxed umask(1) so that other users can use software installed by
Homebrew.
- Call the "real" `brew`(1) command.
Alexander Barton [Sat, 14 May 2022 11:25:32 +0000 (13:25 +0200)]
lsd: Don't use long options in the ls(1) alias
Both the "--date" and "--group-dirs" options are "nice", and I'd like to
set them here, but it looks like long options break the file name
completion logic: when a long option is present, you can't tab-complete
any file or folder name any more, which is _really_ annoying!
So remove those options again (for now)!?
If you wan't to use long options, like the ones removed now here, you
can use a configuration file in ~/.config/lsd/config.yaml, for example.
Write an initial PATH variable to the "ax-io" cache file
This initial PATH becomes overwritten by the path plugin at the
"zprofile" stage later on, but this way "ax-io" stage plugins have a
somewhat saner PATH to begin with ...
Alexander Barton [Wed, 15 Dec 2021 10:12:39 +0000 (11:12 +0100)]
12_locale: Some minor tweaks and refactoring
- Regular expressions aren't anchored, no .* needed at the beginning/end
- fgrep is "non standard", so use "grep -F"
- Quote unknown locale name in message ...
- And use "raw mode" (-r) for read.
Alexander Barton [Mon, 13 Dec 2021 10:00:02 +0000 (11:00 +0100)]
homebrew: Make sure brew(1) command actually works
There are wrapper scripts out there -- at least my own ;-) -- which
are available even on systems where no "real" brew is available, and
therefore this wrapper errors our when called. So not only check for
brew's existence, but if it is working when checking for plugins.
Alexander Barton [Fri, 10 Dec 2021 20:53:52 +0000 (21:53 +0100)]
README.md: Reformat the file a bit
- Add more links, as references at the end of the document.
- Add link to our own GitHub "homepage".
- Emphasis that you really should use Git to install AX-ZSH!
- Fix link to zdharma-continuum/fast-syntax-highlighting
Alexander Barton [Mon, 22 Mar 2021 21:20:09 +0000 (22:20 +0100)]
50_completion: Try to find all available completion functions
Try to add all folders possibly containing completion functions to the
fpath before calling compinit. See <https://github.com/ohmyzsh/ohmyzsh/issues/4614>
for a discussion of this topic, for example. It boils down to:
1. We have to call compinit early,
2. but plugins can add completions later, that won't be found ...
Alexander Barton [Mon, 22 Mar 2021 20:58:34 +0000 (21:58 +0100)]
Get rid of "bash_completion" default plugin
The "bashcompinit" system results in way too many errors, and the
dysfunctional bash completions even shadow working ZSH completion
functions way too often. This makes no sense. Get rid of it!