Commit Graph

26 Commits (master)

Author SHA1 Message Date
Benedict Lee c8337b654e Enable conf.d loading for themes (#713)
Loading of conf.d files for the current theme is done after all other initialisation to ensure that everything the files need is loaded.
5 years ago
Pablo Santiago Blum de Aguiar 168ba68ccc fixup! Remove occurrences of `?` as a glob 5 years ago
Pablo Santiago Blum de Aguiar a4b2f1cfaa Remove occurrences of `?` as a glob
Since Fish Shell 3.0 [1], `?` as a glob is deprecated. Fixes #644

  1. https://github.com/fish-shell/fish-shell/releases/tag/3.0.0
5 years ago
Itzik Ephraim a6a67be60b Use posix stderr redirection (2> instead of ^)
Fish is deprecating `^` as a shortcut for stderr redirection.
Replace with the more common and compatible `2>`.

Fixes #609
6 years ago
Stephen M. Coakley 8aef0b2d33
Handle missing theme setting more gracefully 7 years ago
Stephen M. Coakley 6404410be0 Implement update channels to introduce release versioning (#293) 8 years ago
Derek Stavis 9eb496de86 init: read theme again on key bindings reload 8 years ago
Derek Stavis ac9b419825 init: don't try to double backup key bindings 8 years ago
Derek Willian Stavis 0ca26d01e2 Fix theme key bindings (#334)
* init: load only key bindings from current theme

* theme: reload key bindings on theme change
8 years ago
Pablo Aguiar 77ac6fa261 init: set correct version number (#323) (#331) 8 years ago
Derek Willian Stavis a164ebdd5d init: rewrite init process (#260)
* init: rewrite init process

Now use pure globbing to generate 100% valid function and
completion paths, effectively splitting the init process in two
steps, one which paths are added, and other when initialization
is done (sourcing init).

This initialization code introduces a new interface for
`init.fish` hook, which deprecates the previously used event
model. The new interface injects three variables into `init.fish`:
path, package and bundle. This variables can be used by the
package to autoload paths, use bundled files, etc.

Also supports key bindings by sourcing
$OMF_CONFIG/key_bindings.fish and also key_bindings.fish in
packages (plugins and themes) root directories. This is done
when fish_user_key_bindings is called.

* omf: migrate to new init hook

* omf/templates: migrate to new init and uninstall hooks

* docs: document new init and uninstall hooks interface

* README: update new hook interface spec
8 years ago
Denis Koltsov ce97843850 update version (#323)
* update version constant to 2
8 years ago
Derek Stavis 309fa3bdf1 Remove PATH save/restore code
Fixes #186 by removing the PATH save/restore code from init.fish.

There isn't a single occurence where Oh My Fish code changes the
value of PATH variable.

Plugin code which changes the PATH variable should be aware of
the side-effects and manage PATHs correctly, avoiding duplication.
8 years ago
Bruno Pinto 30ab05445d Add `require` function to support plugin dep
In order to support dependency between plugins a function called
`require` has been added.
9 years ago
Bruno Pinto ceb31c143a Source `init.fish` on each plugin.
Unnecessarily sourcing a `$plugin_name.fish` is affecting the loading
time.
9 years ago
Stephen Coakley 18679d866e Split custom "init.fish" into clearer "before.init.fish" and "init.fish" 9 years ago
Derek Stavis c58d14fe3e Move $OMF_CONFIG variable to $OMF_PATH/init.fish
This PR sets the default value of `OMF_CONFIG` variable in
framework init.fish file. The variable can still be overridden by
the user by setting it on `~/.config/fish/config.fish file`.

This is in preparation to rewriting install script in plain fish,
which will ditch config template and stop replacing `config.fish`
contents in favor of just appending Oh My Fish startup.
9 years ago
Bruno Pinto b36bc03eb0 Remove global OSTYPE variable. 9 years ago
Bruno Pinto 2ac89b5a1c Rename RESET_PATH to ORIGINAL_PATH
This variable records the value of $PATH environment variable before
oh-my-fish is sourced. When we "reload" the framework, we reset $PATH
with this recorded value so that we boot from a clean state.
9 years ago
Bruno Pinto 8aa6bf7ee2 Remove unnecessary code
This was actually trying to load PATHs that do not exist under $OMF_CONFIG
directory and sourcing files that did not exist.
9 years ago
Bruno Pinto 8aa60c55ae Do not source `events.fish`
We don't use it for anything.
9 years ago
Bruno Pinto ae0e4388b6 Back to oh-my-fish organization 9 years ago
Jorge Bucaran 84872300df refactor botched source calls with ^/dev/null 9 years ago
Harrison Heck 7d47220770 Add checks to see if file exists before source.
Fixes #524.
9 years ago
Justin Hileman 0359ba047c Merge `$OMF_CONFIG` and `$OMF_CUSTOM`.
Per conversation with @bpinto in Gitter.

There's no need for two separate directories. You don't have a `.git` and `.git-custom` folder, you just put your config in `.git` :)

The most straightforward interpretation of XDG basedir spec is that user configuration for omf would go in `~/.config/omf`, so let's put it there. The only question is whether omf-generated config (i.e. the `theme` file) should go there as well. By analogy with git, programmatically generated config should probably be merged in with user config. This also makes it so when a user clones their dotfiles to a new machine, both kinds of settings come with it.
9 years ago
Jorge Bucaran 2693a2fd18 %%% United States of the Fish → Wahoo + OMF %%% 9 years ago