mirror of
https://github.com/tiddly-gittly/TidGi-Desktop.git
synced 2025-12-06 02:30:47 -08:00
fix: assign LOCAL_GIT_DIRECTORY to point to actural git folder in packaged electron
https://github.com/desktop/dugite/issues/96
This commit is contained in:
parent
7c30ef4ca0
commit
b05c38b72d
2 changed files with 3 additions and 0 deletions
|
|
@ -29,6 +29,7 @@ import { Observer } from 'rxjs';
|
|||
// @ts-expect-error it don't want .ts
|
||||
// eslint-disable-next-line import/no-webpack-loader-syntax
|
||||
import workerURL from 'threads-plugin/dist/loader?name=gitWorker!./gitWorker.ts';
|
||||
import { LOCAL_GIT_DIRECTORY } from '@/constants/appPaths';
|
||||
|
||||
@injectable()
|
||||
export class Git implements IGitService {
|
||||
|
|
@ -46,6 +47,7 @@ export class Git implements IGitService {
|
|||
}
|
||||
|
||||
private async initWorker(): Promise<void> {
|
||||
process.env.LOCAL_GIT_DIRECTORY = LOCAL_GIT_DIRECTORY;
|
||||
this.gitWorker = await spawn<GitWorker>(new Worker(workerURL));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue