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

fix: add packaging to helia-electron example, bump electron #193

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions examples/helia-electron/dev-app-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
provider: generic
url: https://example.com/auto-updates
updaterCacheDirName: electron-app-updater
43 changes: 43 additions & 0 deletions examples/helia-electron/electron-builder.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
appId: com.electron.app
productName: electron-app
directories:
buildResources: build
files:
- '!**/.vscode/*'
- '!src/*'
- '!electron.vite.config.{js,ts,mjs,cjs}'
- '!{.eslintignore,.eslintrc.cjs,.prettierignore,.prettierrc.yaml,dev-app-update.yml,CHANGELOG.md,README.md}'
- '!{.env,.env.*,.npmrc,pnpm-lock.yaml}'
- '!{tsconfig.json,tsconfig.node.json,tsconfig.web.json}'
asarUnpack:
- resources/**
win:
executableName: electron-app
nsis:
artifactName: ${name}-${version}-setup.${ext}
shortcutName: ${productName}
uninstallDisplayName: ${productName}
createDesktopShortcut: always
mac:
entitlementsInherit: build/entitlements.mac.plist
extendInfo:
- NSCameraUsageDescription: Application requests access to the device's camera.
- NSMicrophoneUsageDescription: Application requests access to the device's microphone.
- NSDocumentsFolderUsageDescription: Application requests access to the user's Documents folder.
- NSDownloadsFolderUsageDescription: Application requests access to the user's Downloads folder.
notarize: false
dmg:
artifactName: ${name}-${version}.${ext}
linux:
target:
- AppImage
- snap
- deb
maintainer: electronjs.org
category: Utility
appImage:
artifactName: ${name}-${version}.${ext}
npmRebuild: true
publish:
provider: generic
url: https://example.com/auto-updates
10 changes: 8 additions & 2 deletions examples/helia-electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
"version": "1.0.0",
"private": true,
"description": "A minimal Electron application with Helia",
"author": "example.com",
"homepage": "https://www.electronjs.org",
"keywords": [
"Electron",
"IPFS",
Expand All @@ -13,14 +15,18 @@
"clean": "echo 'Nothing to clean...'",
"start": "electron .",
"serve": "npm run start",
"test": "xvfb-maybe test-node-example test/*"
"test": "xvfb-maybe test-node-example test/*",
"postinstall": "electron-builder install-app-deps",
"build:win": "electron-builder --win --config",
"build:mac": "electron-builder --mac --config",
"build:linux": "electron-builder --linux --config"
},
"dependencies": {
"helia": "^3.0.1"
},
"devDependencies": {
"electron": "^28.1.4",
"electron-rebuild": "^3.1.1",
"electron-builder": "^24.6.4",
"test-ipfs-example": "^1.0.0",
"xvfb-maybe": "^0.2.1"
},
Expand Down
Loading