2020-11-19 19:16:17 +00:00
|
|
|
if not contains -- "$fish_synced_dir/functions" $fish_function_path
|
2021-09-09 23:50:31 +00:00
|
|
|
set --prepend fish_function_path "$fish_synced_dir/functions"
|
2020-11-19 19:16:17 +00:00
|
|
|
end
|
|
|
|
if not contains -- "$fish_synced_dir/completions" $fish_complete_path
|
2021-09-09 23:50:31 +00:00
|
|
|
set --prepend fish_complete_path "$fish_synced_dir/completions"
|
|
|
|
end
|
|
|
|
if not contains -- "$fish_synced_dir/themes" $fish_themes_path
|
|
|
|
set --path --prepend fish_themes_path "$fish_synced_dir/themes"
|
2020-11-19 19:16:17 +00:00
|
|
|
end
|
2017-03-23 22:42:54 +00:00
|
|
|
|
2020-11-19 19:16:17 +00:00
|
|
|
function _source_synced --description "Sources file from synced dir as well as optional local file"
|
2020-10-02 19:40:17 +00:00
|
|
|
# Sources a config file and corresponding local config file if it exists
|
|
|
|
set -l shared_config "$fish_synced_dir/$argv[1].fish"
|
|
|
|
set -l local_config "$fish_synced_dir/$argv[1].local.fish"
|
|
|
|
if test -f "$shared_config"
|
|
|
|
source "$shared_config"
|
|
|
|
end
|
|
|
|
if test -f "$local_config"
|
|
|
|
source "$local_config"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
if status --is-interactive
|
2020-11-19 19:16:17 +00:00
|
|
|
_source_synced 'init/alias'
|
2020-10-02 19:40:17 +00:00
|
|
|
end
|
2020-11-19 19:16:17 +00:00
|
|
|
_source_synced 'init/paths'
|
|
|
|
_source_synced 'init/env'
|