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
f026e183
Commit
f026e183
authored
Mar 02, 2013
by
Bruno Pinto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updating rvm scripts from rubycut/fish-inwater.
parent
9ad425c7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
plugins/rvm/cd.fish
plugins/rvm/cd.fish
+2
-2
plugins/rvm/rvm.fish
plugins/rvm/rvm.fish
+4
-3
No files found.
plugins/rvm/cd.fish
View file @
f026e183
...
@@ -16,8 +16,8 @@ function cd --description "Change directory"
...
@@ -16,8 +16,8 @@ function cd --description "Change directory"
end
end
break
break
else
else
if
test -s ".rvmrc"
if
begin ; test -s ".rvmrc" ; or test -s ".versions.conf" ; end
eval "rvm reload" > /dev/null
rvm reload 1>/dev/null 2>&1
break
break
else
else
set cwd (dirname "$cwd")
set cwd (dirname "$cwd")
...
...
plugins/rvm/rvm.fish
View file @
f026e183
function rvm -d 'Ruby enVironment Manager'
function rvm -d 'Ruby enVironment Manager'
# run RVM and capture the resulting environment
# run RVM and capture the resulting environment
set -l env_file (mktemp -t rvm.fish.XXXXXXXXXX)
set -l env_file (mktemp -t rvm.fish.XXXXXXXXXX)
bash -c 'source ~/.rvm/scripts/rvm; rvm "$@"; status=$?; env > "$0"; exit $status' $env_file $argv
bash -c 'source ~/.rvm/scripts/rvm; cd .;rvm "$@"; status=$?; env > "$0"; exit $status' $env_file $argv
# apply rvm_* *PATH RUBY_* GEM_* variables from the captured environment
and eval (grep '^rvm\|^[^=]*PATH\|^RUBY_\|^GEM_' $env_file |grep -v _clr| sed '/^[^=]*PATH/y/:/ /; s/^/set -xg /; s/=/ /; s/$/ ;/; s/(//; s/)//')
# apply rvm_* and *PATH variables from the captured environment
and eval (grep '^rvm\|^[^=]*PATH' $env_file | sed '/^[^=]*PATH/y/:/ /; s/^/set -xg /; s/=/ /; s/$/ ;/; s/(//; s/)//')
# clean up
# clean up
rm -f $env_file
rm -f $env_file
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