Skip to content

Commit

Permalink
fix: set explicit release
Browse files Browse the repository at this point in the history
  • Loading branch information
calebboyd committed Jun 22, 2020
1 parent cf23147 commit ae51cc6
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -2,7 +2,7 @@
"name": "nexe",
"description": "Create a single executable out of your Node.js application",
"license": "MIT",
"version": "3.3.2",
"version": "3.3.3",
"contributors": [
"Craig Condon <craig.j.condon@gmail.com> (http://crcn.io)",
"Jared Allard <jaredallard@outlook.com>",
Expand Down
2 changes: 1 addition & 1 deletion src/compiler.ts
Expand Up @@ -112,7 +112,7 @@ export class NexeCompiler {
this.remoteAsset = options.asset
} else {
this.remoteAsset =
'https://github.com/nexe/nexe/releases/download/v3.0.0/' + this.target.toString()
'https://github.com/nexe/nexe/releases/download/v3.3.3/' + this.target.toString()
}
this.src = join(this.options.temp, this.target.version)
this.configureScript = configure + (semverGt(this.target.version, '10.10.0') ? '.py' : '')
Expand Down
6 changes: 3 additions & 3 deletions src/releases.ts
Expand Up @@ -29,15 +29,15 @@ function isBuildableVersion(version: string) {
return !versionsToSkip.includes(major) || version === '4.8.4'
}

export function getLatestGitRelease(options?: any) {
return getJson<GitRelease>('https://api.github.com/repos/nexe/nexe/releases/latest', options)
export function getV3GitRelease(options?: any) {
return getJson<GitRelease>('https://api.github.com/repos/nexe/nexe/releases/7567580/', options)
}

export async function getUnBuiltReleases(options?: any) {
const nodeReleases = await getJson<NodeRelease[]>(
'https://nodejs.org/download/release/index.json'
)
const existingVersions = (await getLatestGitRelease(options)).assets.map(x => getTarget(x.name))
const existingVersions = (await getV3GitRelease(options)).assets.map(x => getTarget(x.name))

const versionMap: { [key: string]: true } = {}
return nodeReleases
Expand Down
4 changes: 2 additions & 2 deletions tasks/build.ts
@@ -1,5 +1,5 @@
import * as nexe from '../lib/nexe'
import { getUnBuiltReleases, getLatestGitRelease } from '../lib/releases'
import { getUnBuiltReleases, getV3GitRelease } from '../lib/releases'
import { runDockerBuild } from './docker'
import { getTarget, targetsEqual, NexeTarget } from '../lib/target'
import { pathExistsAsync, readFileAsync, execFileAsync, semverGt } from '../lib/util'
Expand Down Expand Up @@ -78,7 +78,7 @@ async function build() {
stop()
if (await pathExistsAsync(output)) {
await assertNexeBinary(output)
const gitRelease = await getLatestGitRelease({ headers }),
const gitRelease = await getV3GitRelease({ headers }),
unbuiltReleases = await getUnBuiltReleases({ headers })
if (!unbuiltReleases.some(x => targetsEqual(x, target!))) {
console.log(`${target} already uploaded.`)
Expand Down

0 comments on commit ae51cc6

Please sign in to comment.