Mercurial > hg > octave-nkf
comparison scripts/pkg/pkg.m @ 10821:693e22af08ae
Grammarcheck documentation of m-files
Add newlines between @item fields for readability.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Mon, 26 Jul 2010 21:25:36 -0700 |
parents | be55736a0783 |
children | a4f482e66b65 |
comparison
equal
deleted
inserted
replaced
10820:c44c786f87ba | 10821:693e22af08ae |
---|---|
22 ## @deffnx {Command} pkg @var{command} @var{option} @var{pkg_name} | 22 ## @deffnx {Command} pkg @var{command} @var{option} @var{pkg_name} |
23 ## This command interacts with the package manager. Different actions will | 23 ## This command interacts with the package manager. Different actions will |
24 ## be taken depending on the value of @var{command}. | 24 ## be taken depending on the value of @var{command}. |
25 ## | 25 ## |
26 ## @table @samp | 26 ## @table @samp |
27 ## | |
27 ## @item install | 28 ## @item install |
28 ## Install named packages. For example, | 29 ## Install named packages. For example, |
30 ## | |
29 ## @example | 31 ## @example |
30 ## pkg install image-1.0.0.tar.gz | 32 ## pkg install image-1.0.0.tar.gz |
31 ## @end example | 33 ## @end example |
34 ## | |
32 ## @noindent | 35 ## @noindent |
33 ## installs the package found in the file @file{image-1.0.0.tar.gz}. | 36 ## installs the package found in the file @file{image-1.0.0.tar.gz}. |
34 ## | 37 ## |
35 ## The @var{option} variable can contain options that affect the manner | 38 ## The @var{option} variable can contain options that affect the manner |
36 ## in which a package is installed. These options can be one or more of | 39 ## in which a package is installed. These options can be one or more of |
61 ## performed. | 64 ## performed. |
62 ## @end table | 65 ## @end table |
63 ## | 66 ## |
64 ## @item uninstall | 67 ## @item uninstall |
65 ## Uninstall named packages. For example, | 68 ## Uninstall named packages. For example, |
69 ## | |
66 ## @example | 70 ## @example |
67 ## pkg uninstall image | 71 ## pkg uninstall image |
68 ## @end example | 72 ## @end example |
73 ## | |
69 ## @noindent | 74 ## @noindent |
70 ## removes the @code{image} package from the system. If another installed | 75 ## removes the @code{image} package from the system. If another installed |
71 ## package depends on the @code{image} package an error will be issued. | 76 ## package depends on the @code{image} package an error will be issued. |
72 ## The package can be uninstalled anyway by using the @option{-nodeps} option. | 77 ## The package can be uninstalled anyway by using the @option{-nodeps} option. |
78 ## | |
73 ## @item load | 79 ## @item load |
74 ## Add named packages to the path. After loading a package it is | 80 ## Add named packages to the path. After loading a package it is |
75 ## possible to use the functions provided by the package. For example, | 81 ## possible to use the functions provided by the package. For example, |
82 ## | |
76 ## @example | 83 ## @example |
77 ## pkg load image | 84 ## pkg load image |
78 ## @end example | 85 ## @end example |
86 ## | |
79 ## @noindent | 87 ## @noindent |
80 ## adds the @code{image} package to the path. It is possible to load all | 88 ## adds the @code{image} package to the path. It is possible to load all |
81 ## installed packages at once with the command | 89 ## installed packages at once with the command |
90 ## | |
82 ## @example | 91 ## @example |
83 ## pkg load all | 92 ## pkg load all |
84 ## @end example | 93 ## @end example |
94 ## | |
85 ## @item unload | 95 ## @item unload |
86 ## Removes named packages from the path. After unloading a package it is | 96 ## Removes named packages from the path. After unloading a package it is |
87 ## no longer possible to use the functions provided by the package. | 97 ## no longer possible to use the functions provided by the package. |
88 ## This command behaves like the @code{load} command. | 98 ## This command behaves like the @code{load} command. |
99 ## | |
89 ## @item list | 100 ## @item list |
90 ## Show a list of the currently installed packages. By requesting one or two | 101 ## Show a list of the currently installed packages. By requesting one or two |
91 ## output argument it is possible to get a list of the currently installed | 102 ## output argument it is possible to get a list of the currently installed |
92 ## packages. For example, | 103 ## packages. For example, |
104 ## | |
93 ## @example | 105 ## @example |
94 ## installed_packages = pkg list; | 106 ## installed_packages = pkg list; |
95 ## @end example | 107 ## @end example |
108 ## | |
96 ## @noindent | 109 ## @noindent |
97 ## returns a cell array containing a structure for each installed package. | 110 ## returns a cell array containing a structure for each installed package. |
98 ## The command | 111 ## The command |
112 ## | |
99 ## @example | 113 ## @example |
100 ## [@var{user_packages}, @var{system_packages}] = pkg list | 114 ## [@var{user_packages}, @var{system_packages}] = pkg list |
101 ## @end example | 115 ## @end example |
116 ## | |
102 ## @noindent | 117 ## @noindent |
103 ## splits the list of installed packages into those who are installed by | 118 ## splits the list of installed packages into those who are installed by |
104 ## the current user, and those installed by the system administrator. | 119 ## the current user, and those installed by the system administrator. |
120 ## | |
105 ## @item describe | 121 ## @item describe |
106 ## Show a short description of the named installed packages, with the option | 122 ## Show a short description of the named installed packages, with the option |
107 ## '-verbose' also list functions provided by the package, e.g.: | 123 ## '-verbose' also list functions provided by the package, e.g.: |
124 ## | |
108 ## @example | 125 ## @example |
109 ## pkg describe -verbose all | 126 ## pkg describe -verbose all |
110 ## @end example | 127 ## @end example |
128 ## | |
111 ## @noindent | 129 ## @noindent |
112 ## will describe all installed packages and the functions they provide. | 130 ## will describe all installed packages and the functions they provide. |
113 ## If one output is requested a cell of structure containing the | 131 ## If one output is requested a cell of structure containing the |
114 ## description and list of functions of each package is returned as | 132 ## description and list of functions of each package is returned as |
115 ## output rather than printed on screen: | 133 ## output rather than printed on screen: |
134 ## | |
116 ## @example | 135 ## @example |
117 ## desc = pkg ("describe", "secs1d", "image") | 136 ## desc = pkg ("describe", "secs1d", "image") |
118 ## @end example | 137 ## @end example |
138 ## | |
119 ## @noindent | 139 ## @noindent |
120 ## If any of the requested packages is not installed, pkg returns an | 140 ## If any of the requested packages is not installed, pkg returns an |
121 ## error, unless a second output is requested: | 141 ## error, unless a second output is requested: |
142 ## | |
122 ## @example | 143 ## @example |
123 ## [ desc, flag] = pkg ("describe", "secs1d", "image") | 144 ## [ desc, flag] = pkg ("describe", "secs1d", "image") |
124 ## @end example | 145 ## @end example |
146 ## | |
125 ## @noindent | 147 ## @noindent |
126 ## @var{flag} will take one of the values "Not installed", "Loaded" or | 148 ## @var{flag} will take one of the values "Not installed", "Loaded" or |
127 ## "Not loaded" for each of the named packages. | 149 ## "Not loaded" for each of the named packages. |
150 ## | |
128 ## @item prefix | 151 ## @item prefix |
129 ## Set the installation prefix directory. For example, | 152 ## Set the installation prefix directory. For example, |
153 ## | |
130 ## @example | 154 ## @example |
131 ## pkg prefix ~/my_octave_packages | 155 ## pkg prefix ~/my_octave_packages |
132 ## @end example | 156 ## @end example |
157 ## | |
133 ## @noindent | 158 ## @noindent |
134 ## sets the installation prefix to @file{~/my_octave_packages}. | 159 ## sets the installation prefix to @file{~/my_octave_packages}. |
135 ## Packages will be installed in this directory. | 160 ## Packages will be installed in this directory. |
136 ## | 161 ## |
137 ## It is possible to get the current installation prefix by requesting an | 162 ## It is possible to get the current installation prefix by requesting an |
138 ## output argument. For example, | 163 ## output argument. For example: |
164 ## | |
139 ## @example | 165 ## @example |
140 ## p = pkg prefix | 166 ## p = pkg prefix |
141 ## @end example | 167 ## @end example |
142 ## | 168 ## |
143 ## The location in which to install the architecture dependent files can be | 169 ## The location in which to install the architecture dependent files can be |
144 ## independent specified with an addition argument. For example | 170 ## independent specified with an addition argument. For example: |
145 ## | 171 ## |
146 ## @example | 172 ## @example |
147 ## pkg prefix ~/my_octave_packages ~/my_arch_dep_pkgs | 173 ## pkg prefix ~/my_octave_packages ~/my_arch_dep_pkgs |
148 ## @end example | 174 ## @end example |
175 ## | |
149 ## @item local_list | 176 ## @item local_list |
150 ## Set the file in which to look for information on the locally | 177 ## Set the file in which to look for information on the locally |
151 ## installed packages. Locally installed packages are those that are | 178 ## installed packages. Locally installed packages are those that are |
152 ## typically available only to the current user. For example | 179 ## typically available only to the current user. For example: |
180 ## | |
153 ## @example | 181 ## @example |
154 ## pkg local_list ~/.octave_packages | 182 ## pkg local_list ~/.octave_packages |
155 ## @end example | 183 ## @end example |
184 ## | |
156 ## It is possible to get the current value of local_list with the following | 185 ## It is possible to get the current value of local_list with the following |
186 ## | |
157 ## @example | 187 ## @example |
158 ## pkg local_list | 188 ## pkg local_list |
159 ## @end example | 189 ## @end example |
190 ## | |
160 ## @item global_list | 191 ## @item global_list |
161 ## Set the file in which to look for, for information on the globally | 192 ## Set the file in which to look for, for information on the globally |
162 ## installed packages. Globally installed packages are those that are | 193 ## installed packages. Globally installed packages are those that are |
163 ## typically available to all users. For example | 194 ## typically available to all users. For example: |
195 ## | |
164 ## @example | 196 ## @example |
165 ## pkg global_list /usr/share/octave/octave_packages | 197 ## pkg global_list /usr/share/octave/octave_packages |
166 ## @end example | 198 ## @end example |
199 ## | |
167 ## It is possible to get the current value of global_list with the following | 200 ## It is possible to get the current value of global_list with the following |
201 ## | |
168 ## @example | 202 ## @example |
169 ## pkg global_list | 203 ## pkg global_list |
170 ## @end example | 204 ## @end example |
205 ## | |
171 ## @item rebuild | 206 ## @item rebuild |
172 ## Rebuilds the package database from the installed directories. This can | 207 ## Rebuilds the package database from the installed directories. This can |
173 ## be used in cases where for some reason the package database is corrupted. | 208 ## be used in cases where for some reason the package database is corrupted. |
174 ## It can also take the @option{-auto} and @option{-noauto} options to allow the | 209 ## It can also take the @option{-auto} and @option{-noauto} options to allow the |
175 ## autoloading state of a package to be changed. For example | 210 ## autoloading state of a package to be changed. For example, |
176 ## | 211 ## |
177 ## @example | 212 ## @example |
178 ## pkg rebuild -noauto image | 213 ## pkg rebuild -noauto image |
179 ## @end example | 214 ## @end example |
180 ## | 215 ## |
181 ## will remove the autoloading status of the image package. | 216 ## will remove the autoloading status of the image package. |
217 ## | |
182 ## @item build | 218 ## @item build |
183 ## Builds a binary form of a package or packages. The binary file produced | 219 ## Builds a binary form of a package or packages. The binary file produced |
184 ## will itself be an Octave package that can be installed normally with | 220 ## will itself be an Octave package that can be installed normally with |
185 ## @code{pkg}. The form of the command to build a binary package is | 221 ## @code{pkg}. The form of the command to build a binary package is |
186 ## | 222 ## |