Comments (5)
It's proven really tricky to automatically figure out if those image optimization tools are installed on Mac/Linux. It should work for you. You shouldn't need to add the whole path. If it's available from the command line it should be available to Ant in that situation.
Can you paste the script block? The error you're seeing isn't actually down to the JDK version it's basically not finding a file to concatenate.
from ant-build-script.
Tinas-MacBook-Pro:build tina$ ant build
Buildfile: /Users/tina/Sites/ducklegends/build/build.xml
build:
[echo] Building a Production Environment...
version:
[echo] H5BP Ant Build Script Version 1.1.0
-intro:
[echo] =====================================================================
[echo] Welcome to the HTML5 Boilerplate Build Script!
[echo]
[echo] We're going to get your site all ship-shape and ready for prime time.
[echo]
[echo] This should take somewhere between 15 seconds and a few minutes,
[echo] mostly depending on how many images we're going to compress.
[echo]
[echo] Feel free to come back or stay here and follow along.
[echo] =====================================================================
[echo]
[echo]
-mkdirs:
[echo] Creating directory structure... publish
[echo] The directories publish and intermediate already exist.
-imagespng:
[echo] Optimizing images...
[echo] This part might take a while.
[echo]
[echo] First, we run optipng on the .png files...
[echo] Now, we run advpng on the .png files...
[echo] *** advpng NOT INSTALLED. SKIPPING OPTIMIZATION OF PNGs.
[echo] *** Install advpng to enable advanced png optimization.
[echo] *** For instructions see 'Dependencies' at: https://github.com/h5bp/ant-build-script/wiki/Platform
-imagesjpg:
[echo] Now, we clean up those jpgs...
-js.all.minify:
[echo] Minifying scripts
[apply] /Users/tina/Sites/ducklegends/src/js/game/demo.js:130: ERROR - Parse error. IE8 (and below) will parse trailing commas in array and object literals incorrectly. If you are targeting newer versions of JS, set the appropriate language_in option.
[apply] textureWidth: 512,
[apply] ^
[apply]
[apply] 1 error(s), 0 warning(s)
[apply] Result: 1
-js.main.concat:
[echo] Concatenating Main JS scripts based on index.html...
[exec] Result: 1
[concat] /Users/tina/Sites/ducklegends/intermediate/Exception does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/in does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/thread does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/"main" does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/java.io.FileNotFoundException: does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/index.html does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/(No does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/such does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/file does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/or does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/directory) does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/at does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/java.io.FileInputStream.open(Native does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/Method) does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/at does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/java.io.FileInputStream.(FileInputStream.java:146) does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/at does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/java.io.FileInputStream.(FileInputStream.java:101) does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/at does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/java.io.FileReader.(FileReader.java:58) does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/at does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/FindAttribute.main(Unknown does not exist.
[concat] /Users/tina/Sites/ducklegends/intermediate/Source) does not exist.
-js.scripts.concat:
[echo] Concatenating library file with main script file
-needhtmlrefresh:
[echo] Checking whether the HTML needs to be refreshed
-css:
[echo] Concatenating any @imports...
BUILD FAILED
/Users/tina/Sites/ducklegends/build/build.xml:129: The following error occurred while executing this line:
/Users/tina/Sites/ducklegends/build/build.xml:841: Warning: Could not find file /Users/tina/Sites/ducklegends/css/main.css to copy.
Total time: 8 seconds
is this what you need? thanks so much!!
from ant-build-script.
That's better than what I actually asked for. Fix the following error and your concatenation task will work. What's happening is Closure Compiler is choking on your script file and not doing the minification.
[echo] Minifying scripts
[apply] /Users/tina/Sites/ducklegends/src/js/game/demo.js:130: ERROR - Parse error. IE8 (and below) will parse trailing commas in array and object literals incorrectly. If you are targeting newer versions of JS, set the appropriate language_in option.
[apply] textureWidth: 512,
[apply] ^
[apply]
[apply] 1 error(s), 0 warning(s)
[apply] Result: 1```
from ant-build-script.
ah ok makes sense. I think my problem was misreferencing my files in the project.properties config.. I was trying to create a hierarchy different than the default but kinda n00bed on that.
I moved my build folder to the same directory as my project files and that fixed the errors above, including the advpng
thanks a lot !! this tool is awesome
from ant-build-script.
That was the other piece I was asking about. With directory structures we can sometimes run into problems with the build finding all the files. Happy to hear you got it sorted out.
from ant-build-script.
Related Issues (20)
- Change docs to address confusion HOT 2
- Can't copy minified js directory over to publish HOT 2
- Concatenation after minifying and ADVANCED_OPTIMIZATIONS HOT 5
- Image Optimization Broken on Linux/Mac HOT 9
- Minifying any unconcatenated css files... FileNotFoundException HOT 2
- The gem-sass.jar throws an exception with Foundation 4 HOT 3
- Image Optimization HOT 5
- Rework Image Optimization HOT 15
- CSS reference not updating w/php includes on build HOT 6
- Mavericks Upgrade: Busted Macports for Ant HOT 2
- Unicode characters being inserted between css imports upon concatenation. HOT 5
- css-references not updating in html-file HOT 17
- working with sass stylesheets HOT 1
- set language_in option for closure compiler? HOT 6
- Port to NodeJs HOT 1
- css does not minify/concat correctly when using default main.css HOT 7
- ant validate only validates single page HOT 1
- JS files vanished in publish/ directory HOT 1
- How to use this build script outside my project? HOT 5
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 ant-build-script.