Fix syncing shell env on TCSH and CSH (#6453)

* Fix syncing shell env on TCSH and CSH

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Refactor computeUnixShellEnvironment to be clearer

Signed-off-by: Sebastian Malton <sebastian@malton.name>

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton authored and GitHub committed 2022-10-24 11:36:12 -04:00
1 parent dbed58cfe5
commit d84d2e28a1
3 files changed
+102 -62

No files matched your search

@@ -0,0 +1,11 @@
/**
* Copyright (c) OpenLens Authors. All rights reserved.
* Licensed under MIT License. See LICENSE in root directory for more information.
*/
import { getGlobalOverride } from "../../common/test-utils/get-global-override";
import randomUUIDInjectable from "./random-uuid.injectable";
export default getGlobalOverride(randomUUIDInjectable, () => () => {
throw new Error("Tried to get a randomUUID without override");
});
+14
View File
@@ -0,0 +1,14 @@
/**
* Copyright (c) OpenLens Authors. All rights reserved.
* Licensed under MIT License. See LICENSE in root directory for more information.
*/
import { getInjectable } from "@ogre-tools/injectable";
import { randomUUID } from "crypto";
const randomUUIDInjectable = getInjectable({
id: "random-uuid",
instantiate: () => randomUUID,
causesSideEffects: true,
});
export default randomUUIDInjectable;