Skip to content

Commit

Permalink
Always add revision/release to the RPM filename (#114)
Browse files Browse the repository at this point in the history
* Use the Release (revision) number on the filename
* Fix tests to account to Release(revision)
  • Loading branch information
fcastilloec authored and malept committed May 24, 2019
1 parent e0da5af commit dc75e94
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/installer.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const util = require('./util')
const defaultLogger = debug('electron-installer-redhat')

const defaultRename = function (dest, src) {
return path.join(dest, '<%= name %>-<%= version %>.<%= arch %>.rpm')
return path.join(dest, '<%= name %>-<%= version %>-<%= revision %>.<%= arch %>.rpm')
}

class RedhatInstaller extends common.ElectronInstaller {
Expand Down
4 changes: 2 additions & 2 deletions test/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ describe('cli', function () {

runCLI({ src: 'test/fixtures/app-with-asar/', dest: outputDir, arch: 'x86' })

it('generates a `.rpm` package', () => access(path.join(outputDir, 'footest-0.0.1.x86.rpm')))
it('generates a `.rpm` package', () => access(path.join(outputDir, 'footest-0.0.1-1.x86.rpm')))

cleanupOutputDir(outputDir)
})
Expand All @@ -39,7 +39,7 @@ describe('cli', function () {

runCLI({ src: 'test/fixtures/app-without-asar/', dest: outputDir, arch: 'x86_64' })

it('generates a `.rpm` package', () => access(path.join(outputDir, 'bartest-0.0.1.x86_64.rpm')))
it('generates a `.rpm` package', () => access(path.join(outputDir, 'bartest-0.0.1-1.x86_64.rpm')))

after(() => fs.remove(outputDir))
})
Expand Down

0 comments on commit dc75e94

Please sign in to comment.