Permalink
Browse files

Updates folder structure, fixes #350

  • Loading branch information...
1 parent d009831 commit eebfec70d3681df01495797cf52e2fc28eb1d3ad @ruyadorno ruyadorno committed Sep 3, 2015
Showing with 23 additions and 23 deletions.
  1. 0 { → generators}/all/index.js
  2. 0 { → generators}/app/index.js
  3. 0 { → generators}/app/templates/Gruntfile.js
  4. 0 { → generators}/app/templates/_bower.json
  5. 0 { → generators}/app/templates/_package.json
  6. 0 { → generators}/app/templates/app.coffee
  7. 0 { → generators}/app/templates/app.js
  8. 0 { → generators}/app/templates/app/404.html
  9. BIN { → generators}/app/templates/app/favicon.ico
  10. 0 { → generators}/app/templates/app/robots.txt
  11. 0 { → generators}/app/templates/bowerrc
  12. 0 { → generators}/app/templates/editorconfig
  13. 0 { → generators}/app/templates/gitattributes
  14. 0 { → generators}/app/templates/gitignore
  15. 0 { → generators}/app/templates/index.html
  16. 0 { → generators}/app/templates/jshintrc
  17. 0 { → generators}/app/templates/main.scss
  18. 0 { → generators}/app/templates/requirejs_app.coffee
  19. 0 { → generators}/app/templates/requirejs_app.js
  20. +1 −1 { → generators}/collection/index.js
  21. +1 −1 { → generators}/model/index.js
  22. +1 −1 { → generators}/router/index.js
  23. 0 { → generators}/templates/coffeescript/collection.coffee
  24. 0 { → generators}/templates/coffeescript/model.coffee
  25. 0 { → generators}/templates/coffeescript/requirejs/collection.coffee
  26. 0 { → generators}/templates/coffeescript/requirejs/model.coffee
  27. 0 { → generators}/templates/coffeescript/requirejs/router.coffee
  28. 0 { → generators}/templates/coffeescript/requirejs/view.coffee
  29. 0 { → generators}/templates/coffeescript/router.coffee
  30. 0 { → generators}/templates/coffeescript/view.coffee
  31. 0 {templates → generators/templates/coffeescript}/view.ejs
  32. 0 { → generators}/templates/collection.js
  33. 0 { → generators}/templates/model.js
  34. 0 { → generators}/templates/requirejs/collection.js
  35. 0 { → generators}/templates/requirejs/model.js
  36. 0 { → generators}/templates/requirejs/router.js
  37. 0 { → generators}/templates/requirejs/view.js
  38. 0 { → generators}/templates/router.js
  39. 0 {templates/coffeescript → generators/templates}/view.ejs
  40. 0 { → generators}/templates/view.js
  41. +1 −1 { → generators}/view/index.js
  42. +8 −8 package.json
  43. +2 −2 script-base.js
  44. +2 −2 test/helper.js
  45. +1 −1 test/test-apppath.js
  46. +6 −6 test/test-foo.js
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -3,7 +3,7 @@ var path = require('path');
var util = require('util');
var pascalCase = require('pascal-case');
var yeoman = require('yeoman-generator');
-var scriptBase = require('../script-base');
+var scriptBase = require('../../script-base');
var CollectionGenerator = scriptBase.extend({
constructor: function () {
@@ -3,7 +3,7 @@ var path = require('path');
var util = require('util');
var pascalCase = require('pascal-case');
var yeoman = require('yeoman-generator');
-var scriptBase = require('../script-base');
+var scriptBase = require('../../script-base');
var ModelGenerator = scriptBase.extend({
constructor: function (name) {
@@ -3,7 +3,7 @@ var path = require('path');
var util = require('util');
var pascalCase = require('pascal-case');
var yeoman = require('yeoman-generator');
-var scriptBase = require('../script-base');
+var scriptBase = require('../../script-base');
var RouterGenerator = scriptBase.extend({
constructor: function () {
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -3,7 +3,7 @@ var path = require('path');
var util = require('util');
var pascalCase = require('pascal-case');
var yeoman = require('yeoman-generator');
-var scriptBase = require('../script-base');
+var scriptBase = require('../../script-base');
var ViewGenerator = scriptBase.extend({
constructor: function () {
View
@@ -10,7 +10,7 @@
"backbone"
],
"author": "Yeoman",
- "main": "app/index.js",
+ "main": "generators/app/index.js",
"repository": "yeoman/generator-backbone",
"scripts": {
"test": "mocha --reporter spec"
@@ -35,13 +35,13 @@
},
"license": "BSD",
"files": [
- "all",
- "app",
- "collection",
- "model",
- "router",
- "templates",
- "view",
+ "generators/all",
+ "generators/app",
+ "generators/collection",
+ "generators/model",
+ "generators/router",
+ "generators/templates",
+ "generators/view",
"script-base.js",
"util.js"
]
View
@@ -46,11 +46,11 @@ var ScriptBase = yeoman.generators.NamedBase.extend({
},
_setupSourceRootAndSuffix: function () {
- var sourceRoot = '/templates';
+ var sourceRoot = '/generators/templates';
this.scriptSuffix = '.js';
if (this.env.options.coffee || this.options.coffee) {
- sourceRoot = '/templates/coffeescript';
+ sourceRoot = '/generators/templates/coffeescript';
this.scriptSuffix = '.coffee';
}
View
@@ -7,7 +7,7 @@ exports.createSubGenerator = function (config, type, asserts) {
var deps = [
[helpers.createDummyGenerator(), 'backbone-mocha:' + type]
];
- helpers.run(path.join(__dirname, '../' + type))
+ helpers.run(path.join(__dirname, '../generators/' + type))
.inDir(path.join(__dirname, 'temp'), function () {
fs.writeFileSync('.yo-rc.json', config);
})
@@ -25,7 +25,7 @@ exports.createAppGenerator = function (config, prompts, done) {
var deps = [
[helpers.createDummyGenerator(), 'mocha:app']
];
- helpers.run(path.join(__dirname, '../app'))
+ helpers.run(path.join(__dirname, '../generators/app'))
.inDir(path.join(__dirname, 'temp'), function () {
fs.writeFileSync('.yo-rc.json', config);
})
@@ -21,7 +21,7 @@ describe('backbone generator with appPath option', function () {
var deps = [
[helpers.createDummyGenerator(), 'mocha:app']
];
- helpers.run(path.join(__dirname, '../app'))
+ helpers.run(path.join(__dirname, '../generators/app'))
.inTmpDir(function () {
fs.writeFileSync('.yo-rc.json', config);
})
View
@@ -27,12 +27,12 @@ describe('Backbone generator test', function () {
it('every generator can be required without throwing', function () {
// not testing the actual run of generators yet
- this.all = require('../all');
- this.app = require('../app');
- this.collection = require('../collection');
- this.model = require('../model');
- this.router = require('../router');
- this.view = require('../view');
+ this.all = require('../generators/all');
+ this.app = require('../generators/app');
+ this.collection = require('../generators/collection');
+ this.model = require('../generators/model');
+ this.router = require('../generators/router');
+ this.view = require('../generators/view');
});
describe('create expected files', function () {

0 comments on commit eebfec7

Please sign in to comment.