bump version to 1.10.4 and add error handling for patch copying on Windows
Some checks are pending
CI / general (push) Waiting to run

This commit is contained in:
mr. M 2025-03-14 13:10:03 +01:00
parent 488575eaee
commit 811acaa819
No known key found for this signature in database
GPG key ID: CBD57A2AEDBDA1FB
2 changed files with 23 additions and 20 deletions

View file

@ -1,6 +1,6 @@
{
"name": "@zen-browser/surfer",
"version": "1.10.3",
"version": "1.10.4",
"description": "Simplifying building firefox forks!",
"main": "index.js",
"bin": {

View file

@ -35,26 +35,29 @@ export const copyManual = async (
) {
await remove(resolve(dest, ...getChunked(name)))
}
try {
if (
process.platform == 'win32' &&
!config.buildOptions.windowsUseSymbolicLinks
) {
// Make the directory if it doesn't already exist.
await mkdirp(dirname(resolve(dest, ...getChunked(name))))
if (
process.platform == 'win32' &&
!config.buildOptions.windowsUseSymbolicLinks
) {
// Make the directory if it doesn't already exist.
await mkdirp(dirname(resolve(dest, ...getChunked(name))))
// By default, windows users do not have access to the permissions to create
// symbolic links. As a work around, we will just copy the files instead
await copyFile(
resolve(placeToCheck, ...getChunked(name)),
resolve(dest, ...getChunked(name))
)
} else {
// Create the symlink
await ensureSymlink(
resolve(placeToCheck, ...getChunked(name)),
resolve(dest, ...getChunked(name))
)
// By default, windows users do not have access to the permissions to create
// symbolic links. As a work around, we will just copy the files instead
await copyFile(
resolve(placeToCheck, ...getChunked(name)),
resolve(dest, ...getChunked(name))
)
} else {
// Create the symlink
await ensureSymlink(
resolve(placeToCheck, ...getChunked(name)),
resolve(dest, ...getChunked(name))
)
}
} catch (e) {
console.error(e) // Just in case we have an error
}
const gitignore = readFileSync(resolve(ENGINE_DIR, '.gitignore')).toString()