action-electron-builder icon indicating copy to clipboard operation
action-electron-builder copied to clipboard

Can not get the action to work,

Open richard457 opened this issue 5 years ago • 6 comments

I am having the bellow issue:

info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
child_process.js:660
    throw err;
    ^
Error: Command failed: yarn
    at checkExecSyncError (child_process.js:621:11)
    at execSync (child_process.js:657:15)
    at run (D:\a\_actions\samuelmeuli\action-electron-builder\v1.6.0\index.js:21:27)
    at runAction (D:\a\_actions\samuelmeuli\action-electron-builder\v1.6.0\index.js:109:2)
    at Object.<anonymous> (D:\a\_actions\samuelmeuli\action-electron-builder\v1.6.0\index.js:150:1)
    at Module._compile (internal/modules/cjs/loader.js:959:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:995:10)
    at Module.load (internal/modules/cjs/loader.js:815:32)
    at Function.Module._load (internal/modules/cjs/loader.js:727:14)
    at Function.Module.runMain (internal/modules/cjs/loader.js:1047:10) {
  status: 1

How Can I fix it?

richard457 avatar Dec 05 '20 18:12 richard457

This is my yml file for github action

name: Build/release

on: push

jobs:
  release:
    runs-on: ${{ matrix.os }}

    strategy:
      matrix:
        os: [windows-latest] 
        package_manager: [npm]
        #  macos-latest, ubuntu-latest

    steps:
      - name: Check out Git repository
        uses: actions/checkout@v1

      - name: Install Node.js, NPM and Yarn
        uses:  actions/[email protected]
        with:
          node-version: '10.16.3'

      - name: Build/release Electron app
        uses: samuelmeuli/[email protected]
        with:
          # GitHub token, automatically provided to the action
          # (No need to define this secret in the repo settings)
          github_token: ${{ secrets.github_token }}

          # If the commit is tagged with a version (e.g. "v1.0.0"),
          # release the app after building
          release: ${{ startsWith(github.ref, 'refs/tags/v') }}

richard457 avatar Dec 05 '20 18:12 richard457

I assume it's because you specify package_manager: [npm] but it needs yarn to run?

juliangruber avatar Dec 07 '20 12:12 juliangruber

Actually, they are both supported as per documentation.

richard457 avatar Dec 09 '20 03:12 richard457

Let me test with yarn will get back to you. @juliangruber

richard457 avatar Dec 09 '20 03:12 richard457

The issue is the same @juliangruber

error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
child_process.js:660
    throw err;
    ^

Error: Command failed: yarn
    at checkExecSyncError (child_process.js:621:11)
    at execSync (child_process.js:657:15)
    at run (D:\a\_actions\samuelmeuli\action-electron-builder\v1.6.0\index.js:21:27)
    at runAction (D:\a\_actions\samuelmeuli\action-electron-builder\v1.6.0\index.js:109:2)
    at Object.<anonymous> (D:\a\_actions\samuelmeuli\action-electron-builder\v1.6.0\index.js:150:1)
    at Module._compile (internal/modules/cjs/loader.js:959:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:995:10)
    at Module.load (internal/modules/cjs/loader.js:815:32)
    at Function.Module._load (internal/modules/cjs/loader.js:727:14)
    at Function.Module.runMain (internal/modules/cjs/loader.js:1047:10) {

richard457 avatar Dec 09 '20 03:12 richard457

I have the same problem with vue-cli-plugin-electron-builder (that is implicitly used when adding electron-builder via vue add electron-builder):

Instead now I use the built-in publish of electron-builder.

Here are my configs [ Note the Recommended GitHub Releases Workflow of electron-builder ]:


FYI:

Yarn is strongly recommended instead of npm.

electron-builder #Installation

suhrmann avatar Jan 01 '21 21:01 suhrmann