-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Fix an improve docs * Fix an improve docs * Fix an improve docs
- Loading branch information
Showing
11 changed files
with
125 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ name: Node.js Package | |
|
||
on: | ||
release: | ||
types: [created] | ||
types: [ created ] | ||
|
||
jobs: | ||
publish-npm: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,26 @@ | ||
#! /usr/bin/env node | ||
|
||
import { DEFAULT_FILES_WORKERS_NUM } from '@noodle-graph/scanner'; | ||
import { Command } from 'commander'; | ||
import { Command, Option } from 'commander'; | ||
import figlet from 'figlet'; | ||
|
||
import { run } from './run'; | ||
|
||
export const program = new Command(); | ||
import packageJson from '../package.json'; | ||
|
||
program.name('noodle').version('0.0.5').description(figlet.textSync('Noodle')); | ||
|
||
program.addCommand( | ||
new Command('run') | ||
.description('Using the scanner to search resources relationships.') | ||
.option('--config, -c <string>', 'Path to the scan configuration file.', process.env.NOODLE_CONFIG ?? 'noodle.json') | ||
.option('--output, -o <string>', 'Path the the bundle output directory.', process.env.NOODLE_OUTPUT ?? './noodleScanOutput') | ||
.option('--githubToken <string>', 'GitHub access token.', process.env.NOODLE_GITHUB_TOKEN) | ||
.option('--open', 'Whether to open in the browser the bundled UI when finished.') | ||
.option('--workers', 'Number of scanner workers', DEFAULT_FILES_WORKERS_NUM.toString()) | ||
.option('--verbose', 'Print debug logs') | ||
.action(run) | ||
); | ||
import { run } from './run'; | ||
|
||
program.parse(); | ||
new Command() | ||
.name('noodle') | ||
.version(packageJson.version) | ||
.description(figlet.textSync('Noodle')) | ||
.addCommand( | ||
new Command('run') | ||
.description('Using the scanner to search resources relationships.') | ||
.addOption(new Option('--config, -c <string>', 'Path to the scan configuration file.').default('noodle.json').env('NOODLE_CONFIG')) | ||
.addOption(new Option('--output, -o <string>', 'Path the the bundle output directory.').default('./noodleScanOutput').env('NOODLE_OUTPUT')) | ||
.addOption(new Option('--githubToken <string>', 'GitHub access token.').env('NOODLE_GITHUB_TOKEN')) | ||
.addOption(new Option('--open', 'Whether to open in the browser the bundled UI when finished.')) | ||
.addOption(new Option('--workers <number>', 'Number of scanner workers').default(DEFAULT_FILES_WORKERS_NUM).env('NOODLE_WORKERS').argParser(parseFloat)) | ||
.addOption(new Option('--verbose', 'Print debug logs.')) | ||
.action(run) | ||
) | ||
.parse(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,5 +2,6 @@ | |
"extends": "../../tsconfig.base.json", | ||
"include": [ | ||
"src/**/*.ts", | ||
"package.json", | ||
] | ||
} |
Oops, something went wrong.