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
fa24e676
Commit
fa24e676
authored
Mar 11, 2016
by
Itzik Ephraim
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow selective updates
parent
a0c6213b
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
7 deletions
+26
-7
README.md
README.md
+6
-1
pkg/omf/functions/cli/omf.cli.update.fish
pkg/omf/functions/cli/omf.cli.update.fish
+19
-5
pkg/omf/functions/omf.fish
pkg/omf/functions/omf.fish
+1
-1
No files found.
README.md
View file @
fa24e676
...
...
@@ -33,10 +33,15 @@ fish install
Oh My Fish includes a small utility
`omf`
to fetch and install new packages and themes.
#### `omf update`
#### `omf update`
_`[omf]`_ _`[<package>...]`_
Update the framework and installed packages.
-
When called without arguments, update core and all installed packages.
-
You can choose to update only the core, by running
`omf update omf`
.
-
For selective package update, list only the names of packages you wish to
update. You may still include "omf" in the list to update the core as well.
#### `omf install` _`[<name>|<url>]`_
Install one _or more_ packages.
...
...
pkg/omf/functions/cli/omf.cli.update.fish
View file @
fa24e676
function omf.cli.update
set -l update_core
set -l packages $argv
if test (count $packages) -gt 0
# If several packages are listed, only update core if "omf" is listed among them.
# Also keep "omf" out of the list of packages to update.
set index (contains -i -- omf $packages)
and set -e packages[$index]
or set -e update_core
else
set packages (omf.packages.list --installed)
end
if set -q update_core
if omf.core.update
echo (omf::em)"Oh My Fish is up to date."(omf::off)
else
echo (omf::err)"Oh My Fish failed to update."(omf::off)
echo "Please open a new issue here → "(omf::em)"github.com/oh-my-fish/oh-my-fish/issues"(omf::off)
end
end
for package in
(omf.packages.list --installed)
for package in
$packages
omf.packages.update $package
end
end
pkg/omf/functions/omf.fish
View file @
fa24e676
...
...
@@ -59,7 +59,7 @@ function omf -d "Oh My Fish"
omf.cli.theme $arguments
case "u" "update"
omf.cli.update
omf.cli.update
$arguments
case "*"
echo (omf::err)"$argv[1] option not recognized"(omf::off) 1^&2
...
...
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