Skip to content

Commit

Permalink
debug after electron build
Browse files Browse the repository at this point in the history
  • Loading branch information
ivansglazunov committed Apr 26, 2024
1 parent 9246ffa commit 0e1b098
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 11 deletions.
13 changes: 2 additions & 11 deletions .github/workflows/build-and-publish-reusable-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,9 +162,6 @@ jobs:
ls
mv ${{inputs.app-name}}-${{needs.get-app-version.outputs.app-version}}.AppImage ${{inputs.app-name}}.AppImage
tar -czvf ${{inputs.app-name}}.tar.gz ${{inputs.app-name}}.AppImage
- name: And a README (to work around GitHub double-zips)
run: |
echo "More information: https://deep.foundation" > electron/dist/README.txt
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -236,16 +233,13 @@ jobs:
run: |
cd electron/dist/mac-arm64
ditto -c -k --keepParent ${{inputs.app-name}}.app ${{inputs.app-name}}.app.zip
- name: And a README (to work around GitHub double-zips)
run: |
echo "More information: https://deep.foundation" > electron/dist/mac/README.txt
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Mac
path: |
electron/dist/mac/${{inputs.app-name}}.app.zip
electron/dist/mac/README.txt
electron/dist/mac-arm64/${{inputs.app-name}}.app.zip
electron/dist/mac-arm64/README.txt
windows:
name: Windows
needs: [get-app-version,sync-electron-app-version]
Expand Down Expand Up @@ -309,9 +303,6 @@ jobs:
run: |
cd electron && dir && cd dist && dir
tar.exe -a -c -f ${{inputs.app-name}}.zip "${{inputs.app-name}} Setup ${{needs.get-app-version.outputs.app-version}}.exe"
- name: And a README (to work around GitHub double-zips)
run: |
echo "More information: https://deep.foundation" > electron/dist/README.txt
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
Expand Down
12 changes: 12 additions & 0 deletions electron/recover-after-electron-build.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,18 @@ const macAppPath = 'dist/mac/sdk.app/Contents/Resources/app';
const appPath = process.platform === 'win32' ? windowsAppPath : process.platform === 'darwin' ? macAppPath : linuxAppPath;

exports.default = async function(context) {
if (process.platform === 'win32') {
try {
console.log('outDir', fs.readFileSync(`${context.outDir}`));
console.log('appOutDir', fs.readFileSync(`${context.appOutDir}`));
console.log('resources', fs.readFileSync(`${context.appOutDir}\resources`));
console.log('app', fs.readFileSync(`${context.appOutDir}\\resources\\app`));
console.log('build', fs.readFileSync(`${context.appOutDir}\\resources\\app\\build`));
console.log('src', fs.readFileSync(`${context.appOutDir}\\resources\\app\\build\\src`));
} catch(e) {
console.log('error', e);
}
}
try {
if (fs.existsSync(`${appPath}${delimetr}${typesPath}`))fs.rmSync(`${appPath}${delimetr}${typesPath}`, { recursive: true });
shell(`cp -r ${typesPath} ${appPath}${delimetr}${typesPath}`);
Expand Down

0 comments on commit 0e1b098

Please sign in to comment.