Comments (5)
After some fiddling, the only syntax that seems to work for me is:
build: {
files: [{
cwd: 'src/',
src: ['assets/ico/**/*.svg'],
dest: 'build/',
expand: false
}]
}
So I still don't know what exactly was going wrong, but hope this is of help!
from grunt-svg2png.
Thanks @ismay, I'm glad you got it working :)
Recent changes had broke the old config options and I'm a bit behind on my Grunt files knowledge to understand exactly how it should work. I believe it's now correct though!
from grunt-svg2png.
I'm glad you got it working :)
Me too :)! I think I made a couple of mistakes in the config at first, but the final config should have worked with expand:true
instead of expand:false
(if I'm not misinterpreting Grunt's documentation: http://gruntjs.com/configuring-tasks#files).
I believe it's now correct though!
Is it this commit that should have fixed the dynamic mapping: 7297635? Because I can take a look and see if everything's working as expected now, if you'd like.
from grunt-svg2png.
Something happened between the last version and this one. I had been using the following config, which worked just fine:
svg2png: {
svg: {
files: [{
src: '<%= source %>/_assets/images/**/*.svg',
dest: '<%= source %>/assets/img'
}]
}
},
but now, I've had to modify it to this to make it work:
svg2png: {
svg: {
files: [{
expand: false,
cwd: '<%= source %>/_assets/images/',
src: ['**/*.svg'],
dest: '<%= source %>/assets/img'
}]
}
},
I am happy that I can still make it work, but it doesn't seem to follow the same structure as some of my other grunt tasks, and since it worked fine previously, something doesn't feel right here. Are there any plans to look into this, or do I change the config to what's working and move on? Thanks!
from grunt-svg2png.
This doesn't seem to work anymore. If I do try this, the rasterization process just hangs up at 0, and nothing happens.
from grunt-svg2png.
Related Issues (20)
- Double size (@2x) HOT 3
- Image widths/aspect ratios not maintained HOT 3
- Output is SVG source on Windows HOT 4
- `spawn ENAMETOOLONG` when trying to process too many files or files with long pathes HOT 1
- Process hangs even though it is pointing to the right files HOT 5
- Allow size output setting of png HOT 2
- svg2png fails without message; libfontconfig.so.1 dependency problem HOT 2
- Prefix for png files
- Resize option HOT 2
- Progress bar is too long
- flatten: true not working
- Task Hangs HOT 1
- Warning: Path must be a string. Received [ 'path/to/one/of/the/svgs' ]
- Fails on Mac OS Sierra HOT 1
- Fatal error: write EPIPE HOT 6
- Not rasterizing HOT 1
- update ‘phantomjs’ package references to ‘phantomjs-prebuilt’ HOT 1
- Should use a carraige return on the progress bar instead of a new line? HOT 1
- Module ignores grunt filter function
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from grunt-svg2png.