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
cd78009a
Commit
cd78009a
authored
Jul 09, 2014
by
Bruno Pinto
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #180 from syl20bnr/macosx_compatibility
parents
ef0f1f8c
c137a4f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
themes/syl20bnr/fish_prompt.fish
themes/syl20bnr/fish_prompt.fish
+4
-4
No files found.
themes/syl20bnr/fish_prompt.fish
View file @
cd78009a
...
@@ -111,8 +111,8 @@ function fish_prompt -d "Write out the left prompt of the syl20bnr theme"
...
@@ -111,8 +111,8 @@ function fish_prompt -d "Write out the left prompt of the syl20bnr theme"
end
end
set ps_git $colbwhite"git:"$colbcyan$git_branch_name$git_info$colnormal"@"$colbred$git_repo_name
set ps_git $colbwhite"git:"$colbcyan$git_branch_name$git_info$colnormal"@"$colbred$git_repo_name
if test "$basedir_name" != "$git_repo_name"
if test "$basedir_name" != "$git_repo_name"
set -l basedir_depth (echo (__syl20bnr_git_repo_base) |
cut -d "/" --output-delimiter=" " -f 1-
| wc -w)
set -l basedir_depth (echo (__syl20bnr_git_repo_base) |
sed "s/\// /g"
| wc -w)
set -l depth (echo (pwd) |
cut -d "/" --output-delimiter=" " -f 1-
| wc -w)
set -l depth (echo (pwd) |
sed "s/\// /g"
| wc -w)
set depth (math $depth - $basedir_depth)
set depth (math $depth - $basedir_depth)
set ps_git $ps_git$colbwhite":"$colbgreen$basedir_name$colnormal"("$depth")"
set ps_git $ps_git$colbwhite":"$colbgreen$basedir_name$colnormal"("$depth")"
end
end
...
@@ -127,7 +127,7 @@ function fish_prompt -d "Write out the left prompt of the syl20bnr theme"
...
@@ -127,7 +127,7 @@ function fish_prompt -d "Write out the left prompt of the syl20bnr theme"
# '/' without the current directory and depth.
# '/' without the current directory and depth.
set -l ps_pwd ""
set -l ps_pwd ""
if test -z "$ps_git"
if test -z "$ps_git"
set -l depth (echo (pwd) |
cut -d "/" --output-delimiter=" " -f 1-
| wc -w)
set -l depth (echo (pwd) |
sed "s/\// /g"
| wc -w)
set -l in_home (echo (pwd) | grep ~)
set -l in_home (echo (pwd) | grep ~)
if test -n "$in_home"
if test -n "$in_home"
set ps_pwd $colbwhite"home"
set ps_pwd $colbwhite"home"
...
@@ -150,7 +150,7 @@ function fish_prompt -d "Write out the left prompt of the syl20bnr theme"
...
@@ -150,7 +150,7 @@ function fish_prompt -d "Write out the left prompt of the syl20bnr theme"
if test -n "$vi_mode"
if test -n "$vi_mode"
set ps_vi $colnormal"["$vi_mode$colnormal"]"
set ps_vi $colnormal"["$vi_mode$colnormal"]"
end
end
if test "$fish_key_bindings" = "fish_vi_key_bindings"
if test "$fish_key_bindings" = "fish_vi_key_bindings"
-o "$fish_key_bindings" = "my_fish_key_bindings"
set ps_vi (fish_vi_prompt_cm)
set ps_vi (fish_vi_prompt_cm)
end
end
...
...
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