Permalink
Browse files

chore: move non grunt scripts to scripts

  • Loading branch information...
1 parent 2784b72 commit 30228039cd11d55ed3327a4ae563ef5872eec327 @rgaskill rgaskill committed with vojtajina Apr 6, 2013
View
@@ -3,6 +3,7 @@
tmp
test
tasks
+scripts
docs
TODO.md
View
@@ -21,7 +21,7 @@ module.exports = (grunt) ->
server: ['lib/**/*.js']
client: ['static/karma.src.js']
grunt: ['grunt.js', 'tasks/**/*.js']
- init: ['init-dev-env.js']
+ scripts: ['scripts/*.js']
build:
client: '<%= files.client %>'
@@ -59,9 +59,9 @@ module.exports = (grunt) ->
files:
src: '<%= files.grunt %>'
options: JSHINT_NODE
- init:
+ scripts:
files:
- src: '<%= files.init %>'
+ src: '<%= files.scripts %>'
options: JSHINT_NODE
client:
files:
@@ -15,7 +15,7 @@ are some tips to get you started.
* Init your workspace
```bash
-$ ./init-dev-env.js
+$ ./scripts/init-dev-env.js
```
* Checkout a new branch (usually based on `master`) and name it accordingly to what
View
@@ -1 +0,0 @@
-node init-dev-env.js
File renamed without changes.
View
@@ -0,0 +1,2 @@
+set __dirname=%~dp0
+node %__dirname%init-dev-env.js
@@ -6,15 +6,16 @@ var exec = require('child_process').exec;
var isWin = !!process.platform.match(/^win/);
-var validateCommitPath = '../../tasks/lib/validate-commit-msg.js';
-var gitHookPath = '.git/hooks/commit-msg';
+var validateCommitPath = '../../scripts/validate-commit-msg.js';
+var gitHookPath = __dirname+'/../.git/hooks/commit-msg';
-var nodeModulesPath = 'node_modules';
+var nodeModulesPath = __dirname+'/../node_modules';
var karmaPath = '..';
-var nmKarmaPath = 'node_modules/karma';
+var nmKarmaPath = __dirname+'/../node_modules/karma';
//Add Hook "validate-commit-msg"
var gitHookSetup = function(){
+
if (fs.existsSync(gitHookPath)) {
fs.unlinkSync(gitHookPath);
console.log('Existing link removed:', gitHookPath);
@@ -38,7 +39,8 @@ var selfLinkSetup = function() {
fs.symlinkSync(karmaPath, nmKarmaPath, 'dir');
};
-// Check for gurnt-cli
+
+// Check for grunt-cli
var installGruntCli = function(callback) {
console.log('Installing grunt-cli...');
@@ -64,7 +66,7 @@ var checkForGruntCli = function(callback) {
exec('grunt --version', function (error, stdout) {
- if ( error ) {
+ if ( error ){
installGruntCli(callback);
} else {
console.log('grunt-cli is already installed:');
File renamed without changes.
View
@@ -1,7 +1,7 @@
module.exports = function(grunt) {
var exec = require('child_process').exec;
- var changelog = require('./lib/changelog');
+ var changelog = require('./../scripts/changelog');
/**
* Bump version
@@ -1,5 +1,5 @@
describe 'changelog', ->
- ch = require '../../../tasks/lib/changelog'
+ ch = require '../../../scripts/changelog'
describe 'parseRawCommit', ->
@@ -1,5 +1,5 @@
describe 'validate-commit-msg', ->
- m = require '../../../tasks/lib/validate-commit-msg'
+ m = require '../../../scripts/validate-commit-msg'
errors = []
VALID = true

0 comments on commit 3022803

Please sign in to comment.