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

Add deb and rpm builds for distribution #2895

Open
wants to merge 4 commits into
base: v5
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
16 changes: 16 additions & 0 deletions .github/workflows/compile-and-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,20 @@ jobs:
name: ${{ runner.os }}
path: ./dist/install/${{ runner.os == 'macOS' && 'darwin' || runner.os }}/

- name: Upload RPM
if: runner.os == 'linux'
uses: actions/upload-artifact@v3
with:
name: RPM
path: ./dist/install/rpm/

- name: Upload DEB
if: runner.os == 'linux'
uses: actions/upload-artifact@v3
with:
name: DEB
path: ./dist/install/deb/

draft:
name: Draft Github Release
needs: [checkversion, compile]
Expand Down Expand Up @@ -139,4 +153,6 @@ jobs:
./bundles/Windows/firebot-${{ needs.checkversion.outputs.version }}-full.nupkg
./bundles/Windows/RELEASES
./bundles/Linux/firebot-v${{ needs.checkversion.outputs.version }}-linux-x64.tar.gz
./bundles/DEB/firebotv5_${{ needs.checkversion.outputs.version }}_x86_64.deb
./bundles/RPM/firebotv5-${{ needs.checkversion.outputs.version }}-1.x86_64.rpm
./bundles/macOS/firebot-v${{ needs.checkversion.outputs.version }}-macos-x64.dmg
20 changes: 14 additions & 6 deletions grunt/compile.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,28 +46,36 @@ module.exports = function (grunt) {
shell: {
'compile-darwin': {
command: `npx --no-install electron-installer-dmg "${macPathIn}" firebot-v${version}-macos-x64 --out="${macPathOut}" --background="${macDmgBg}" --icon="${macDmgIcon}" --title="Firebot Installer" --debug`
},
'compile-rpm': {
command: `npx --no-install electron-installer-redhat --src dist/pack/Firebot-linux-x64/ --dest dist/install/rpm/ --arch x86_64 --bin "Firebot v5"`
},
'compile-deb': {
command: `npx --no-install electron-installer-debian --src dist/pack/Firebot-linux-x64/ --dest dist/install/deb/ --arch x86_64 --bin "Firebot v5"`
}
}
});

grunt.loadNpmTasks('grunt-electron-installer');
grunt.loadNpmTasks('grunt-contrib-compress');
let compileCommand;
let compileCommands = ['cleanup:install'];
switch (grunt.config.get('platform')) {
case 'win64':
compileCommand = 'create-windows-installer:win64';
compileCommands.push('create-windows-installer:win64');
break;

case 'linux':
compileCommand = 'compress:linux';
compileCommands.push('compress:linux');
compileCommands.push('shell:compile-rpm');
compileCommands.push('shell:compile-deb');
break;

case 'darwin':
compileCommand = 'shell:compile-darwin';
compileCommands.push('shell:compile-darwin');
break;

default:
throw new Error('unknonw platform');
}
grunt.registerTask('compile', ['cleanup:install', compileCommand]);
};
grunt.registerTask('compile', compileCommands);
};
Loading
Loading