Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: default gulp task should not list tasks #5935

Merged
merged 1 commit into from
Jul 21, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ env:

before_install:
- source ./scripts/ci/env.sh
- npm i -g npm@^5.0.1
- npm i -g npm@^5.3.0

install:
- npm install
Expand Down
2 changes: 1 addition & 1 deletion gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ require('ts-node').register({
// The gulp tsconfig file maps specific imports to relative paths. In combination with ts-node
// this doesn't work because the JavaScript output will still refer to the imports instead of
// to the relative path. Tsconfig-paths can be used to support path mapping inside of Node.
require("tsconfig-paths").register({
require('tsconfig-paths').register({
baseUrl: path.dirname(tsconfigPath),
paths: tsconfig.compilerOptions.paths
});
Expand Down
14 changes: 5 additions & 9 deletions tools/gulp/tasks/default.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
import {task} from 'gulp';
const gulp = require('gulp');
import {yellow} from 'chalk';

task('default', ['help']);

task('help', function() {
const taskList = Object.keys(gulp.tasks)
.filter(taskName => !taskName.startsWith(':'))
.filter(taskName => !taskName.startsWith('ci:'))
.filter(taskName => taskName != 'default')
.sort();

console.log(`\nHere's a list of supported tasks:\n `, taskList.join('\n '));
console.log(`\nYou're probably looking for "test" or "serve:devapp".\n\n`);
console.log();
console.log('Please specify a gulp task you want to run.');
console.log(`You're probably looking for ${yellow('test')} or ${yellow('serve:devapp')}.`);
console.log();
});