Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
O
oh-my-fish
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nanahira
oh-my-fish
Commits
658c8ad5
Commit
658c8ad5
authored
Sep 29, 2015
by
Bruno
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #79 from derekstavis/omf-config-to-init
Move $OMF_CONFIG variable to $OMF_PATH/init.fish
parents
456f6fc4
c58d14fe
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
5 deletions
+7
-5
bin/install
bin/install
+1
-2
init.fish
init.fish
+6
-0
templates/config.fish
templates/config.fish
+0
-3
No files found.
bin/install
View file @
658c8ad5
...
...
@@ -89,8 +89,7 @@ omf_install() {
touch
${
fish_config_file
}
>
/dev/null 2>&1
test
!
-w
${
fish_config_file
}
&&
die
"Fish configuration file is not writable, aborting."
sed
"s|{{OMF_PATH}}|
$(
echo
"
${
OMF_PATH
}
"
|
sed
-e
"s|
$HOME
|
\$
HOME|"
)
|;
\
s|{{OMF_CONFIG}}|
$(
echo
"
${
OMF_CONFIG
}
"
|
sed
-e
"s|
$HOME
|
\$
HOME|"
)
|"
\
sed
"s|{{OMF_PATH}}|
$(
echo
"
${
OMF_PATH
}
"
|
sed
-e
"s|
$HOME
|
\$
HOME|"
)
|"
\
"
${
OMF_PATH
}
/templates/config.fish"
>
"
${
fish_config_file
}
"
if
[
!
-d
"
${
OMF_CONFIG
}
"
]
;
then
...
...
init.fish
View file @
658c8ad5
...
...
@@ -26,6 +26,12 @@ else
set -gx ORIGINAL_PATH $PATH
end
# Set OMF_CONFIG if not set.
if not set -q OMF_CONFIG
set -q XDG_CONFIG_HOME; or set -l XDG_CONFIG_HOME "$HOME/.config"
set -gx OMF_CONFIG "$XDG_CONFIG_HOME/omf"
end
# Save the head of function path and autoload core functions
set -l user_function_path $fish_function_path[1]
set fish_function_path[1] $OMF_PATH/lib
...
...
templates/config.fish
View file @
658c8ad5
# Path to your oh-my-fish.
set -g OMF_PATH {{OMF_PATH}}
# Path to your oh-my-fish configuration.
set -g OMF_CONFIG {{OMF_CONFIG}}
### Configuration required to load oh-my-fish ###
# Note: Only add configurations that are required to be set before oh-my-fish is loaded.
# For common configurations, we advise you to add them to your $OMF_CONFIG/init.fish file or
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment