Skip to content

Commit

Permalink
feat: use ci flag instead of is-travis
Browse files Browse the repository at this point in the history
  • Loading branch information
vlasy committed Jan 9, 2020
1 parent d00f2f1 commit c1ef2ec
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 7 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@
"glob": "7.1.6",
"gradle-to-js": "2.0.0",
"inversify": "5.0.1",
"is-travis": "^2.0.0",
"js-yaml": "3.13.1",
"lodash": "4.17.15",
"memfs": "3.0.3",
Expand Down
3 changes: 1 addition & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import updateNotifier from 'update-notifier';
import { ScanningStrategyDetectorUtils } from './detectors/utils/ScanningStrategyDetectorUtils';
import { PracticeImpact } from './model';
import { ServiceType } from './detectors/ScanningStrategyDetector';
import isTravis from 'is-travis';
import debug from 'debug';

class DXScannerCommand extends Command {
Expand Down Expand Up @@ -70,7 +69,7 @@ class DXScannerCommand extends Command {

let scanResult = await scanner.scan();

if (scanResult.needsAuth && !isTravis) {
if (scanResult.needsAuth && !flags.ci) {
if (ScanningStrategyDetectorUtils.isGitHubPath(scanPath) || scanResult.serviceType === ServiceType.github) {
authorization = await cli.prompt('Insert your GitHub personal access token. https://github.com/settings/tokens\n', {
type: 'hide',
Expand Down
4 changes: 0 additions & 4 deletions types/is-travis/index.d.ts

This file was deleted.

0 comments on commit c1ef2ec

Please sign in to comment.