Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Packaging app for platform too slow, #270

Closed
Luncher opened this issue Mar 28, 2016 · 43 comments
Closed

Packaging app for platform too slow, #270

Luncher opened this issue Mar 28, 2016 · 43 comments
Assignees
Labels

Comments

@Luncher
Copy link

Luncher commented Mar 28, 2016

my application File size:

[luncher@localhost release-test]$ ls
app build dist node_modules package.json
[luncher@localhost release-test]$ du -sh ./*
108M ./app
420K ./build
423M ./dist
170M ./node_modules
4.0K ./package.json
[luncher@localhost release-test]$

my build options:
"build": {
"asar": false,
"app-bundle-id": "hr.creaticon.eatodo",
"app-category-type": "public.app-category.productivity",
"iconUrl": "http://eatodo.s3.amazonaws.com/icon.ico"
},

@develar
Copy link
Member

develar commented Mar 28, 2016

Please specify target platform. See #181 (comment)

@Luncher
Copy link
Author

Luncher commented Mar 28, 2016

"scripts": {
"dist": "npm run dist:osx && npm run dist:win",
"dist:osx": "build --platform darwin -d",
"dist:win": "build --platform win32 -d"
},

I've specified version:
npm run dist:win

@Luncher
Copy link
Author

Luncher commented Mar 28, 2016

When I specified asar equal to false, too slow~

@develar
Copy link
Member

develar commented Mar 28, 2016

Slow — what is your target and host OS? Without asar is ok? CPU, RAM? Please provide exact timing — use time command.

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Without asar is ok.

[luncher@localhost SingleIDEServer]$ uname -a
Linux localhost.localdomain 3.17.4-301.fc21.x86_64 #1 SMP Thu Nov 27 19:09:10 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux


[luncher@localhost SingleIDEServer]$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 60
model name : Intel(R) Core(TM) i5-4210M CPU @ 2.60GHz
stepping : 3
microcode : 0x1c
cpu MHz : 1086.617
cache size : 3072 KB


I am waiting for the end of time command

Removing /data/SingleIDEServer/build/release-test/dist/win-x64
Packaging app for platform win32 x64 using electron v0.37.2

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Packaging app for platform win32 x64 using electron v0.37.2

real 108m29.333s
user 197m33.096s
sys 17m57.266s
[luncher@localhost release-test]$

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Who can help me check why? Thank you

@develar
Copy link
Member

develar commented Mar 29, 2016

I, but I will have time only on weekend. It is interesting why asar=false is slow, but default asar=true not. Why you cannot use asar?

@develar
Copy link
Member

develar commented Mar 29, 2016

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Because I have to modify the app folder inside the file,

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Thank you 👍

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Ask a question.

extra Resources option whether to extract out of resources from app.asar

@develar
Copy link
Member

develar commented Mar 29, 2016

extraResources option whether to extract out of resources from app.asar

No. Copied separately. Not in the asar in any case.

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

What other way to extract the rar files?

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

Why do I use mac computer to compile windows installer is very slow. . .

@Luncher
Copy link
Author

Luncher commented Mar 29, 2016

There are other ways you can see the log information?

@develar
Copy link
Member

develar commented Mar 30, 2016

Set DEBUG env to *

@develar
Copy link
Member

develar commented Apr 2, 2016

@Luncher electron-winstaller-fixed 2.0.6-beta.6 published, please try npm update and build.

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

When I upgraded version of the compiler prompt an error:


Packaging app for platform linux x64 using electron v0.37.4
Error: Please specify project homepage
at LinuxPackager. (/data/LocalHolaStudio/release/node_modules/electron-builder/src/linuxPackager.ts:178:13)
at [object Generator].next (native)
at processImmediate as _immediateCallback
From previous event:
at tsAwaiter (/data/LocalHolaStudio/release/node_modules/electron-builder/src/awaiter.ts:10:51)
at Object.build (/data/LocalHolaStudio/release/node_modules/electron-builder/src/builder.ts:30:59)
at Object. (/data/LocalHolaStudio/release/node_modules/electron-builder/src/build-cli.ts:41:2)
at Module._compile (module.js:413:34)
at Object.Module._extensions..js (module.js:422:10)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
at Function.Module.runMain (module.js:447:10)
at startup (node.js:141:18)
at node.js:933:3


dev json:

"license": "ISC",
"devDependencies": {
"electron-builder": "^3.2.0",
"electron-prebuilt": "^0.37.4"
},
"build": {
"asar": false,
"iconUrl": "http://7xsec6.com1.z0.glb.clouddn.com/icon.ico",
"app-bundle-id": "holaverse.studio",
"app-category-type": "public.app-category.productivity",
"osx": {
"title": "HolaStudio",
"background": "build/background.png",
"icon": "build/icon.icns",
"icon-size": 128,
"contents": [
{
"x": 355,
"y": 125,
"type": "link",
"path": "/Applications"
},
{
"x": 155,
"y": 125,
"type": "file"
}
]
}
}

@develar
Copy link
Member

develar commented Apr 4, 2016

Linux requires homepage now because it is important for Ubuntu Software Center (see https://github.com/electron-userland/electron-builder/blob/master/docs/options.md#user-content-#DevMetadata-homepage)

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

thank you man。How do I build Linux Package URL? I have not put the project on github.

@develar
Copy link
Member

develar commented Apr 4, 2016

@Luncher Does your project have public project page?

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

Have a website, you see, write directly to this site can it?
HolaStudio

@develar
Copy link
Member

develar commented Apr 4, 2016

@Luncher Yes. Any URL is accepted. You can specify your company or product web site. Developer Web site (https://wiki.ubuntu.com/SoftwareCenter).

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

thank you.

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

chore: update NuGet to 3

Seems to not work, I have built a windows compiler environment

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

How to set linux installation package icon it? After the update version of the icon disappeared. The build application json option to move to the developer json.

@develar
Copy link
Member

develar commented Apr 4, 2016

Seems to not work, I have built a windows compiler environment

Sorry, don't understand. It is slow, or error was thrown?

How to set linux installation package icon it? After the update version of the icon disappeared.

Do you mean that you upgrade electron-builder version from 2 to 3 and no more Linux icon? Or did you use 3.x before, but after npm update linux icon is not correctly applied?

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

another question,my dev package.json:


"scripts": {
"dist": "npm run dist:linux && npm run dist:win",
"dist:osx": "build --platform darwin -d",
"dist:win": "build --platform win32 -d",
"dist:linux": "build --platform linux -d"
},


-d What does it mean?

@develar
Copy link
Member

develar commented Apr 4, 2016

-d What does it mean?

--dist "to package in a distributable format (e.g. DMG, windows installer, NuGet package)" You don't need to pass it because your script name has prefix dist:.

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

When I run:

[luncher@localhost release]$ npm run dist:linux

[email protected] dist:linux /data/LocalHolaStudio/release
build --platform linux --arch all -d

Installing app dependencies for arch ia32 to /data/LocalHolaStudio/release/app

Reading icns family from /data/LocalHolaStudio/release/build/icon.icns...
Extracting icons from /icon.icns...
Saved 'is32' element to /tmp/electron-builder-24640n5k0r9R0yYIi/icon_16x16x32.png.
Saved 'il32' element to /tmp/electron-builder-24640n5k0r9R0yYIi/icon_32x32x32.png.
Saved 'ih32' element to /tmp/electron-builder-24640n5k0r9R0yYIi/icon_48x48x32.png.
Saved 'it32' element to /tmp/electron-builder-24640n5k0r9R0yYIi/icon_128x128x32.png.
Saved 'ic08' element to /tmp/electron-builder-24640n5k0r9R0yYIi/icon_256x256x32.png.
Saved 'ic09' element to /tmp/electron-builder-24640n5k0r9R0yYIi/icon_512x512x32.png.
Extracted 6 images from /icon.icns.


my icons:

[luncher@localhost build]$ ls
background.png icon.icns icon.ico
[luncher@localhost build]$ pwd
/data/LocalHolaStudio/release/build
[luncher@localhost build]$


I watched electron packager help documentation.:

icon - String

Currently you must look for conversion tools in order to supply an icon in the format required by the platform:

OS X: .icns
Windows: .ico (See below for details on non-Windows platforms)
Linux: this option is not required, as the dock/window list icon is set via the icon option in the BrowserWindow constructor. Setting the icon in the file manager is not currently supported.

I do not know how to set the app icon for linux platform

@develar
Copy link
Member

develar commented Apr 4, 2016

I do not know how to set the app icon for linux platform

electron-builder does it. If it doesn't work, it is a regression. I will check.

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

thank you

@develar
Copy link
Member

develar commented Apr 4, 2016

@Luncher Cannot confirm Linux icon bug. Please file separate issue (and provide details — "the icon disappeared" — where icon is missed?).

@develar
Copy link
Member

develar commented Apr 4, 2016

@Luncher Your answer about NuGet 3 is important, please try it and report how does it work for you (if doesn't work, don't forget to attach debug log).

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

I compiled a problem in the mac platform. Will the mac system log file where to see it?I compiled a

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

I installed dmg file, double-click the apk file, the system prompts can not be opened

@develar
Copy link
Member

develar commented Apr 4, 2016

@Luncher DEBUG=electron-windows-installer:* npm run dist -- --platform win32 (correct npm script name — in your case may be dist:win).

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

My first question is in the translation of the mac system files can not be installed and turned on. You can help to look at this issue.

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

Do you know the log file is?

@develar
Copy link
Member

develar commented Apr 4, 2016

@Luncher Please don't mix several questions in one issue. Please file another issue.

@Luncher
Copy link
Author

Luncher commented Apr 4, 2016

ok

@develar
Copy link
Member

develar commented Apr 5, 2016

@develar develar closed this as completed Apr 5, 2016
@develar develar self-assigned this Apr 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants