Grunt IIS kill on exit
module.exports = function (grunt) { | |
grunt.initConfig({ | |
// Some other grunt tasks | |
iisexpress: { | |
server: { | |
options: { | |
path: require('path').resolve('.') + '/[PATH OF WEBSITE HERE]', | |
killOn: 'iis.kill' | |
} | |
} | |
} | |
}); | |
process.on('SIGINT', function() { | |
grunt.event.emit('iis.kill'); | |
process.exit(1); | |
}); | |
grunt.registerTask('default', ['iisexpress', /*Other tasks here*/]); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This comment has been minimized.
Using Grunt module https://www.npmjs.org/package/grunt-iisexpress for this.
it is awesome to save having to open to Visual Studio which can kill any PC in a few minutes.