-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
install:addon
will show a deprecation warning then it will run the …
…`install` command. Changed the verbage on install-npm.
- Loading branch information
1 parent
d8a1081
commit 9465b05
Showing
4 changed files
with
77 additions
and
33 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 |
---|---|---|
@@ -1,21 +1,24 @@ | ||
'use strict'; | ||
|
||
var Command = require('../models/command'); | ||
var SilentError = require('../errors/silent'); | ||
var Promise = require('../ext/promise'); | ||
var InstallCommand = require('./install'); | ||
var chalk = require('chalk'); | ||
|
||
module.exports = Command.extend({ | ||
module.exports = InstallCommand.extend({ | ||
name: 'install:addon', | ||
description: 'Deprecated. You can use `ember install` for ember-cli addons.', | ||
description: 'This command has been deprecated. Please use `ember install` instead.', | ||
works: 'insideProject', | ||
|
||
anonymousOptions: [ | ||
'<addon-name>' | ||
], | ||
|
||
run: function() { | ||
var err = 'This command has been deprecated. Please use `ember install '; | ||
err += '<addonName>` instead.'; | ||
return Promise.reject(new SilentError(err)); | ||
init: function() { | ||
var warning = 'This command has been deprecated. Please use `ember '; | ||
warning += 'install <addonName>` instead.'; | ||
this.ui.writeLine(chalk.red(warning)); | ||
|
||
if (this._super.init) { | ||
this._super.init(); | ||
} | ||
} | ||
}); |
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