AppScreenshot icon indicating copy to clipboard operation
AppScreenshot copied to clipboard

sh build.sh YOUR_APP_NAME

Open lovebdsobuj opened this issue 9 years ago • 12 comments

What does it mean? When command prompt by this command sh build.sh YOUR_APP_NAME I got error.

Capturing /build/YOUR_APP_NAME/android-5.png
build.sh: line 13: ./phantomjs-1.9.2/bin/phantomjs: cannot execute binary file: Exec format error

lovebdsobuj avatar Jan 18 '16 20:01 lovebdsobuj

node app.js command nothing happened...

lovebdsobuj avatar Jan 18 '16 20:01 lovebdsobuj

Hi,

  1. After node app.js, node will be waiting for connections. Just leave it alone.
  2. Then try this command sh build.sh Sample

yisheng avatar Jan 20 '16 03:01 yisheng

After node app.js, node will be waiting for connections. Just leave it alone.

I waited minimum 5-10 minute, still nothing happened.

lovebdsobuj avatar Jan 20 '16 11:01 lovebdsobuj

You don't have to wait, just leave it alone and run sh build.sh Sample command.

yisheng avatar Jan 21 '16 04:01 yisheng

README.md updated, check it out: https://github.com/yisheng/AppScreenshot#sample

yisheng avatar Jan 21 '16 04:01 yisheng

After node app.js I leave the cmd window, and visited the screenshot preview link - http://localhost:3000/?app=Sample&device=3.5&index=1 and its work.

After that I open new cmd window and run sh build.sh Sample

But I got error...

screenshot_00095_20h52m41s

But, thanks to you, its a very nice and useful project... Hope I'll add some Android device frame...

lovebdsobuj avatar Jan 21 '16 14:01 lovebdsobuj

It's because the PhantomJS binary is the Mac version.

Sorry I didn't test it on Windows yet, I'll fix it today.

yisheng avatar Jan 22 '16 01:01 yisheng

@lovebdsobuj Are you using cygwin to run sh files?

yisheng avatar Jan 22 '16 10:01 yisheng

No, i used git bash...

lovebdsobuj avatar Jan 22 '16 11:01 lovebdsobuj

It works...

I have installed latest phantomjs for windows. I copied phantomjs directory into AppScreenshot folder. Next I edit build.sh file line 12 ./phantomjs-1.9.2/bin/phantomjs ./phantomjs-1.9.2/examples/rasterize.js to ./phantomjs/bin/phantomjs ./phantomjs/examples/rasterize.js

and run the command line node app.js and sh build.sh Sample

and finally it works, chrome.


N.B. No need to copy phantomjs installed directory just need to add location where installed latest phantomjs in build.sh.

lovebdsobuj avatar Jan 22 '16 12:01 lovebdsobuj

Yes, you got it!

yisheng avatar Jan 22 '16 12:01 yisheng