Skip to content

Instantly share code, notes, and snippets.

@pascalwacker
Last active July 14, 2018 11:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pascalwacker/1890fada34b60c9b95175f83b0f0b14f to your computer and use it in GitHub Desktop.
Save pascalwacker/1890fada34b60c9b95175f83b0f0b14f to your computer and use it in GitHub Desktop.
Create Electron Executables (on Linux)
#####################################################
# Replace these: #
# #
# replace "your-name" at --executable-name #
# replace "/path/to" at --icon #
# #
# Create Icons: #
# https://www.npmjs.com/package/electron-icon-maker #
#####################################################
echo "build linux"
electron-packager ./ --executable-name=your-name --platform=linux --arch=ia32 --icon=/path/to/icons/png/1024x1024.png --out=release-builds --overwrite
electron-packager ./ --executable-name=your-name --platform=linux --arch=x64 --icon=/path/to/icons/png/1024x1024.png --out=release-builds --overwrite
echo "build windows"
electron-packager ./ --executable-name=your-name --platform=win32 --arch=ia32 --icon=/path/to/icons/win/icon.ico --out=release-builds --overwrite
electron-packager ./ --executable-name=your-name --platform=win32 --arch=x64 --icon=/path/to/icons/win/icon.ico --out=release-builds --overwrite
echo "build mac"
electron-packager ./ --executable-name=your-name --platform=darwin --arch=x64 --icon=/path/to/icons/mac/icon.icns --out=release-builds --overwrite
@pascalwacker
Copy link
Author

If any one has an idea how to automatically pack the windows output in a single .exe executable to ship, please let me know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment