appId: org.CocoRobo.XGOEdu
copyright: Copytright © 2021 CocoRobo LTD
productName: XGOEdu
npmRebuild: true
asar: true

directories:
  buildResources: dist/
  output: dist/

extraResources:
  - from: src/static/common/about_logo.png
    to: CocoRoboAbout.png
  - from: src/static/common/preloader_1.gif
    to: Preloader1.gif
  - from: src/static/common/download.gif
    to: Download.gif

publish:
  provider: github
  owner: CocoRoboLabs
  repo: uploaderv2
  releaseType: release
  token: f4869551b495e2521e6b2c6530b5cf3cfd1c0158
  private: true

mac:
  target: 
    - pkg
 # category: public.app-category.tools
  icon: src/static/common/cocorobo_.icns
  hardenedRuntime: true
  entitlements: build/entitlements.mac.plist
  entitlementsInherit: build/entitlements.mac.plist
  artifactName: XGOEdu Installer v${version}.${ext}
  extraFiles:
    - from: src/static/mac/tools
      to: tools
  extraResources:
    - from: src/static/common/cocorobo_black.png
      to: CocoRobo_Tray.png
    - from: src/static/common/cocorobo_white.png
      to: CocoRobo_Press.png
    - from: src/static/common/verifyCert.bash
      to: verifyCert.bash
    - from: src/static/common/ca.crt
      to: ca.crt

dmg:
  contents:
    - type: link
      path: /Applications
      x: 410
      y: 220
    - type: file
      x: 130
      y: 220
    - type: file
      x: 270
      y: 80
      name: WiFi Module Driver's installer.pkg
      path: src/static/mac/Silicon Labs VCP Driver.pkg
pkg:
  installLocation: /Applications
  scripts: ../build/pkg-scripts
  welcome: build/resources/welcome.txt

win:
  target: 
    - target: nsis
      arch:
        - x64
        - ia32
  icon: src/static/common/cocorobo.ico
  artifactName: XGOEdu Installer v${version}.${ext}
  extraFiles:
    - from: src/static/win/cp210x_drivers
      to: cp210x_drivers
    - from: src/static/win/python
      to: python
    - from: src/static/win/tools
      to: tools
  extraResources:
    - from: src/static/common/cocorobo.ico
      to: CocoRobo_Tray.ico
    - from: src/static/win/ca.bat
      to: ca.bat
    - from: src/static/common/ca.crt
      to: ca.crt

nsis:
  oneClick: false
  perMachine: true
  allowToChangeInstallationDirectory: true
  allowElevation: true
  installerSidebar: src/static/win/installer-sidebar-image.bmp
  include: src/static/win/installer.nsh

linux:
  target:
    - deb
    - AppImage
  icon: src/static/common/cocorobo.png
  artifactName: XGOEdu Installer v${version}.${ext}
  extraFiles:
    - from: src/static/linux/tools
      to: tools
  extraResources:
    - from: src/static/common/cocorobo_black.png
      to: CocoRobo_Tray.png