Skip to content

Commit 843bad7

Browse files
committed
Fix option name
1 parent 61b1a8a commit 843bad7

8 files changed

Lines changed: 16 additions & 16 deletions

File tree

lib/node_modules/@stdlib/_tools/docs/www/readme-database/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ Options:
206206
-V, --version Print the package version.
207207
--pattern pattern Inclusion glob pattern.
208208
--ignore pattern Exclusion glob pattern.
209-
--base Internal URL base path.
209+
--base path Internal URL base path.
210210
```
211211

212212
</section>

lib/node_modules/@stdlib/_tools/docs/www/readme-fragment-file-tree/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ The function accepts the following `options`:
5252
- **dir**: root directory from which to search for package READMEs. May be either an absolute path or a path relative to the current working directory. Default: current working directory.
5353
- **pattern**: glob pattern used to find packages. Default: `'**/package.json'` (note: pattern **must** end with `package.json`).
5454
- **ignore**: list of glob patterns used to exclude matches.
55-
- **version**: semantic versioning number or branch name.
55+
- **base**: internal URL base path.
5656

5757
To search from an alternative directory, set the `dir` option.
5858

@@ -115,13 +115,13 @@ function done( error ) {
115115
}
116116
```
117117

118-
To have internal URLs of the READMEs link to the correct version of the documentation, set the `version` option.
118+
To have internal URLs of the READMEs link to relative (or absolute) documentation pages with a specified base path, set the `base` option.
119119

120120
<!-- run-disable -->
121121

122122
```javascript
123123
var opts = {
124-
'version': 'v0.0.87'
124+
'base': '/docs/api/v0.0.90/'
125125
};
126126

127127
build( './build', opts, done );
@@ -216,7 +216,7 @@ Options:
216216
-V, --version Print the package version.
217217
--pattern pattern Inclusion glob pattern.
218218
--ignore pattern Exclusion glob pattern.
219-
--release version Semantic versioning number or branch name.
219+
--base path Internal URL base path.
220220
-o, --out directory Output directory.
221221
```
222222

lib/node_modules/@stdlib/_tools/docs/www/readme-fragment-file-tree/bin/cli

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,8 @@ function main() {
7373
opts.ignore = flags.ignore;
7474
}
7575
}
76-
if ( flags.release ) {
77-
opts.version = flags.release;
76+
if ( flags.base ) {
77+
opts.base = flags.base;
7878
}
7979
if ( !flags.out ) {
8080
err = new Error( 'insufficient arguments. Must provide an output directory.' );

lib/node_modules/@stdlib/_tools/docs/www/readme-fragment-file-tree/docs/usage.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ Options:
77
-V, --version Print the package version.
88
--pattern pattern Inclusion glob pattern.
99
--ignore pattern Exclusion glob pattern.
10-
--release version Semantic versioning number or branch name.
10+
--base path Internal URL base path.
1111
-o, --out directory Output directory.
1212

lib/node_modules/@stdlib/_tools/docs/www/readme-fragment-file-tree/etc/cli_opts.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"pattern",
44
"ignore",
55
"out",
6-
"release"
6+
"base"
77
],
88
"boolean": [
99
"help",
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"pattern": "**/package.json",
33
"ignore": [],
4-
"version": "develop"
4+
"base": "/docs/api/develop/"
55
}

lib/node_modules/@stdlib/_tools/docs/www/readme-fragment-file-tree/lib/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ var debug = logger( 'readme-fragment-file-tree:async' );
4747
* @param {string} [options.dir] - root directory from which to search for package READMEs
4848
* @param {string} [options.pattern='**\/package.json'] - glob pattern
4949
* @param {StringArray} [options.ignore] - glob pattern(s) to exclude matches
50-
* @param {string} [options.version='develop'] - semantic versioning number or branch name
50+
* @param {string} [options.base="/docs/api/develop/"] - base path for internal URLs
5151
* @param {Function} clbk - callback
5252
* @throws {TypeError} first argument must be a string
5353
* @throws {TypeError} options argument must be an object

lib/node_modules/@stdlib/_tools/docs/www/readme-fragment-file-tree/lib/validate.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ var RE = /package\.json$/;
4242
* @param {string} [options.dir] - root directory from which to search for package READMEs
4343
* @param {string} [options.pattern] - glob pattern
4444
* @param {StringArray} [options.ignore] - glob pattern(s) to exclude matches
45-
* @param {string} [options.version] - semantic versioning number or branch name
45+
* @param {string} [options.base] - base path for internal URLs
4646
* @returns {(Error|null)} error object or null
4747
*
4848
* @example
@@ -82,10 +82,10 @@ function validate( opts, options ) {
8282
return new TypeError( 'invalid option. `ignore` option must be a string array. Option: `' + opts.ignore + '`.' );
8383
}
8484
}
85-
if ( hasOwnProp( options, 'version' ) ) {
86-
opts.version = options.version;
87-
if ( !isString( opts.version ) ) {
88-
return new TypeError( 'invalid option. `version` option must be a primitive string. Option: `' + opts.version + '`.' );
85+
if ( hasOwnProp( options, 'base' ) ) {
86+
opts.base = options.base;
87+
if ( !isString( opts.base ) ) {
88+
return new TypeError( 'invalid option. `base` option must be a primitive string. Option: `' + opts.base + '`.' );
8989
}
9090
}
9191
return null;

0 commit comments

Comments
 (0)