grunt-asset-revisions
Advanced tools
Comparing version 0.1.0 to 0.1.1
{ | ||
"name": "grunt-asset-revisions", | ||
"description": "Generate revisions of assets.", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"author": "vanetix <matmcfarland@gmail.com>", | ||
@@ -6,0 +6,0 @@ "main": "Gruntfile.js", |
@@ -42,2 +42,11 @@ # grunt-asset-revisions [![Build Status](https://travis-ci.org/vanetix/grunt-asset-revisions.png?branch=master)](https://travis-ci.org/vanetix/grunt-asset-revisions) | ||
**Rename** | ||
> original filenames will be renamed | ||
```javascript | ||
rename: { | ||
src: ['path/to/assets/**'] | ||
} | ||
``` | ||
## License (MIT) | ||
@@ -44,0 +53,0 @@ Copyright (c) 2013 Matt McFarland |
@@ -15,3 +15,4 @@ /* | ||
var path = require('path'), | ||
var fs = require('fs'), | ||
path = require('path'), | ||
crypto = require('crypto'); | ||
@@ -57,8 +58,14 @@ | ||
if(f.flatten) { | ||
r = path.basename(r); | ||
if(f.dest) { | ||
if(f.flatten) { | ||
r = path.basename(r); | ||
} | ||
r = path.join(f.dest, r); | ||
grunt.file.copy(file, r); | ||
grunt.log.write(file + ' ').oklns(r); | ||
} else { | ||
fs.renameSync(file, r); | ||
grunt.log.write(file + ' renamed to ').oklns(r); | ||
} | ||
grunt.file.copy(file, path.join(f.dest, r)); | ||
grunt.log.write(file + ' ').oklns(r); | ||
}); | ||
@@ -65,0 +72,0 @@ }); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6237
82
57
1