Skip to content
This repository has been archived by the owner on Jul 8, 2020. It is now read-only.

Commit

Permalink
work on #31 - filename extensions for controller, services
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Grupp committed Jan 20, 2015
1 parent 81419f9 commit da25a2b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions controller/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';
var yeoman = require('yeoman-generator');
var _s = require('underscore.string');
var utils = require('../utils/utils.js');
var _s = require('underscore.string');

var MGenerator = yeoman.generators.NamedBase.extend({

Expand All @@ -24,7 +24,7 @@ var MGenerator = yeoman.generators.NamedBase.extend({
writing: function () {
// create controller with snake-case file name
var folder = 'app/' + this.moduleFolder + '/controllers/';
this.template('_controller.js', folder + this.fileName + '.js');
this.template('_controller.js', folder + this.fileName + '-ctrl.js');
}
});

Expand Down
2 changes: 1 addition & 1 deletion service/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ var MGenerator = yeoman.generators.NamedBase.extend({
writing: function () {
// create service with snake-case file name
var folder = 'app/' + this.moduleFolder + '/services/';
this.template('_service.js', folder + this.fileName + '.js');
this.template('_service.js', folder + this.fileName + '-service.js');
}
});

Expand Down

0 comments on commit da25a2b

Please sign in to comment.