• Will Chen's avatar
    Get electron forge logs (#2035) · e7525e02
    Will Chen 提交于
    <!-- CURSOR_SUMMARY -->
    > [!NOTE]
    > Improves release workflow logging and visibility during publishing.
    > 
    > - Run `electron-forge publish` directly instead of `npm run publish`
    to surface full logs
    > - Expand `DEBUG` to
    `"@electron/*,electron-forge:*,electron-windows-installer:main"` for
    granular Electron Forge and Windows installer output in `release.yml`
    > 
    > <sup>Written by [Cursor
    Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
    498d93aff656dc635bc60880a3887d3d67ddf291. This will update automatically
    on new commits. Configure
    [here](https://cursor.com/dashboard?tab=bugbot).</sup>
    <!-- /CURSOR_SUMMARY -->
    
    
    
    <!-- This is an auto-generated description by cubic. -->
    ---
    ## Summary by cubic
    Expose detailed Electron Forge logs in the release workflow by running
    electron-forge publish directly (instead of npm) and setting DEBUG to
    "@electron/*,electron-forge:*,electron-windows-installer:main". This
    improves visibility and makes publish failures easier to debug.
    
    <sup>Written for commit 498d93aff656dc635bc60880a3887d3d67ddf291.
    Summary will update automatically on new commits.</sup>
    
    <!-- End of auto-generated description by cubic. -->
    
    
    
    <!-- greptile_comment -->
    
    <h3>Greptile Summary</h3>
    
    
    This PR improves debugging capabilities for the release workflow by
    enhancing electron-forge logging. It adds more granular DEBUG flags
    (`electron-forge:*` and `electron-windows-installer:main`) and switches
    from `npm run publish` to direct `electron-forge publish` execution to
    prevent npm from suppressing logs, following electron-forge's official
    support documentation.
    
    - Added more comprehensive DEBUG environment variables for better
    visibility into the build process
    - Changed to direct `electron-forge publish` command to ensure logs are
    properly captured
    - Removed implicit `npm run clean` step (redundant in CI environment
    with fresh checkout)
    
    <h3>Confidence Score: 5/5</h3>
    
    
    - This PR is safe to merge with no risk
    - The changes are minimal and focused on improving debugging visibility.
    Switching from `npm run publish` to `electron-forge publish` only
    removes the redundant clean step, which is unnecessary in CI
    environments that start from fresh checkouts. The additional DEBUG flags
    provide better logging without changing any build logic.
    - No files require special attention
    
    <h3>Important Files Changed</h3>
    
    
    
    
    | Filename | Overview |
    |----------|----------|
    | .github/workflows/release.yml | Enhanced debug logging and switched to
    direct `electron-forge publish` for better log visibility |
    
    </details>
    
    
    
    <h3>Sequence Diagram</h3>
    
    ```mermaid
    sequenceDiagram
        participant GHA as GitHub Actions
        participant WF as Release Workflow
        participant NPM as npm
        participant EF as electron-forge
        participant Logger as Debug Logger
    
        Note over GHA,Logger: Previous Flow (npm run publish)
        GHA->>WF: Trigger release workflow
        WF->>NPM: npm run publish
        NPM->>NPM: Execute clean script
        NPM->>EF: electron-forge publish
        EF->>Logger: Log output (suppressed by npm)
        Logger-->>NPM: Limited logs
        NPM-->>WF: Exit code only
    
        Note over GHA,Logger: New Flow (direct electron-forge)
        GHA->>WF: Trigger release workflow
        WF->>EF: electron-forge publish (direct)
        activate Logger
        Note over Logger: DEBUG=@electron/*,<br/>electron-forge:*,<br/>electron-windows-installer:main
        EF->>Logger: Full debug logs
        Logger-->>WF: Complete logs visible
        deactivate Logger
        EF-->>WF: Exit code + logs
    ```
    
    <!-- greptile_other_comments_section -->
    
    <!-- /greptile_comment -->
    e7525e02
名称
最后提交
最后更新
.cursor/rules 正在载入提交数据...
.devcontainer 正在载入提交数据...
.github 正在载入提交数据...
.husky 正在载入提交数据...
assets 正在载入提交数据...
docs 正在载入提交数据...
drizzle 正在载入提交数据...
e2e-tests 正在载入提交数据...
packages/@dyad-sh 正在载入提交数据...
scaffold 正在载入提交数据...
scripts 正在载入提交数据...
shared 正在载入提交数据...
src 正在载入提交数据...
testing 正在载入提交数据...
tools 正在载入提交数据...
worker 正在载入提交数据...
workers/tsc 正在载入提交数据...
.cursorignore 正在载入提交数据...
.env.example 正在载入提交数据...
.eslintrc.json 正在载入提交数据...
.gitattributes 正在载入提交数据...
.gitignore 正在载入提交数据...
.oxlintrc.json 正在载入提交数据...
.prettierignore 正在载入提交数据...
.prettierrc 正在载入提交数据...
AGENTS.md 正在载入提交数据...
CONTRIBUTING.md 正在载入提交数据...
LICENSE 正在载入提交数据...
README.md 正在载入提交数据...
SECURITY.md 正在载入提交数据...
biome.json 正在载入提交数据...
components.json 正在载入提交数据...
drizzle.config.ts 正在载入提交数据...
forge.config.ts 正在载入提交数据...
forge.env.d.ts 正在载入提交数据...
index.html 正在载入提交数据...
merge.config.ts 正在载入提交数据...
package-lock.json 正在载入提交数据...
package.json 正在载入提交数据...
playwright.config.ts 正在载入提交数据...
tsconfig.app.json 正在载入提交数据...
tsconfig.json 正在载入提交数据...
tsconfig.node.json 正在载入提交数据...
vite.main.config.mts 正在载入提交数据...
vite.preload.config.mts 正在载入提交数据...
vite.renderer.config.mts 正在载入提交数据...
vite.worker.config.mts 正在载入提交数据...
vitest.config.ts 正在载入提交数据...