/**
 * Grunt-Shell
 * @description Run shell commands.
 * @docs https://github.com/sindresorhus/grunt-shell
 */

var config = require("../Config");

module.exports = {
	"deleteGitHooks" : {
		"command" : "rm -rf .git/hooks/",
		"options" : {
			"stdout" : true,
			"stderr" : true,
			"failOnError" : true
		},
	},
	"hookUpGit" : {
		"command" : "mkdir .git/hooks/ && cp Build/Git-Hooks/pre-commit .git/hooks/",
		"options" : {
			"stdout" : true,
			"stderr" : true,
			"failOnError" : true
		},
	}
};

/**
 * Grunt-Shell
 * @description Run shell commands.
 * @docs https://github.com/sindresorhus/grunt-shell
 */

var os = require('os'),
	config = require("../Config"),
	isWin = /^win/.test(os.platform());

module.exports = {
	"deleteGitHooks" : {
		"command" : isWin ? "rmdir .git\\hooks\\ /s /q" : "rm -rf .git/hooks/",
		"options" : {
			"stdout" : true,
			"stderr" : true,
			"failOnError" : true
		}
	},
	"hookUpGit" : {
		"command" : "mkdir .git/hooks/ && cp Build/Git-Hooks/pre-commit .git/hooks/",
		"options" : {
			"stdout" : true,
			"stderr" : true,
			"failOnError" : true
		}
	}
};

Implement a hostname check to prevent errors while running 'grunt init' on windows based machines