Remove snap repackaging
This commit is contained in:
@@ -55,7 +55,6 @@
|
|||||||
"buildResources": "res",
|
"buildResources": "res",
|
||||||
"output": "build"
|
"output": "build"
|
||||||
},
|
},
|
||||||
"afterAllArtifactBuild": "./dist/scripts/afterAllArtifactBuild.js",
|
|
||||||
"afterPack": "./dist/scripts/afterPack.js"
|
"afterPack": "./dist/scripts/afterPack.js"
|
||||||
},
|
},
|
||||||
"author": "Thomas Nordquist",
|
"author": "Thomas Nordquist",
|
||||||
|
|||||||
@@ -1,24 +0,0 @@
|
|||||||
import * as fs from 'fs-extra'
|
|
||||||
import * as path from 'path'
|
|
||||||
import { chdir } from 'process'
|
|
||||||
import { exec } from './util'
|
|
||||||
|
|
||||||
export default async function(info: any) {
|
|
||||||
for (const snapFile of info.artifactPaths) {
|
|
||||||
if (/\.snap$/.test(snapFile)) {
|
|
||||||
const originalDir = __dirname
|
|
||||||
const dirname = path.dirname(snapFile)
|
|
||||||
chdir(dirname)
|
|
||||||
|
|
||||||
await exec('sudo', ['unsquashfs', snapFile])
|
|
||||||
await exec('sudo', ['rm', snapFile])
|
|
||||||
await exec('sudo', ['chmod', '-R', 'g-s', 'squashfs-root'])
|
|
||||||
|
|
||||||
// Add command line argument to disable the sandbox
|
|
||||||
await exec('sudo', ['snap', 'run', 'snapcraft', 'pack', 'squashfs-root', '--output', snapFile])
|
|
||||||
await exec('sudo', ['rm', '-rf', 'squashfs-root'])
|
|
||||||
|
|
||||||
chdir(originalDir)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user