See gruntjs/grunt-contrib-symlink#9 for details.
Last active
August 29, 2015 14:15
-
-
Save schnittstabil/d8f8dd6cd40fd030bc17 to your computer and use it in GitHub Desktop.
grunt-contrib-symlink overwrite test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = function(grunt) { | |
// Project configuration. | |
grunt.initConfig({ | |
pkg: grunt.file.readJSON('package.json'), | |
symlink: { | |
options: { | |
overwrite: true, | |
}, | |
overwrite: { | |
src: 'sources-new', | |
dest: 'build/symlinkToSource', | |
}, | |
}, | |
}); | |
grunt.loadNpmTasks('grunt-contrib-symlink'); | |
grunt.registerTask('overwrite', ['symlink:overwrite']); | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "grunt-contrib-symlink-overwrite-test", | |
"version": "1.0.0", | |
"description": "", | |
"author": { | |
"name": "Michael Mayer", | |
"email": "michael@schnittstabil.de" | |
}, | |
"license": "MIT", | |
"main": "index.js", | |
"scripts": { | |
"clean": "rm -rf build sources-new sources-old", | |
"setup-test": "mkdir build sources-new sources-old && touch sources-old/a-file && ln -s ../sources-old build/symlinkToSource", | |
"check": "if [ -f sources-old/a-file ]; then echo success; else echo fail && false; fi;", | |
"test": " npm run clean && npm run setup-test && grunt overwrite && npm run check" | |
}, | |
"devDependencies": { | |
"grunt": "^0.4.5", | |
"grunt-contrib-symlink": "^0.3.0" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment