mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
move remove config to make targets
Signed-off-by: Sebastian Malton <smalton@mirantis.com>
This commit is contained in:
parent
69ce254b81
commit
b48b38c393
7
Makefile
7
Makefile
@ -38,16 +38,23 @@ test: binaries/client
|
||||
|
||||
.PHONY: integration-linux
|
||||
integration-linux: binaries/client build-extension-types build-extensions
|
||||
ifdef XDF_CONFIG_HOME
|
||||
rm -rf ${XDG_CONFIG_HOME}/.config/Lens
|
||||
else
|
||||
rm -rf ${HOME}/.config/Lens
|
||||
endif
|
||||
yarn build:linux
|
||||
yarn integration
|
||||
|
||||
.PHONY: integration-mac
|
||||
integration-mac: binaries/client build-extension-types build-extensions
|
||||
rm ${HOME}/Library/Application\ Support/Lens
|
||||
yarn build:mac
|
||||
yarn integration
|
||||
|
||||
.PHONY: integration-win
|
||||
integration-win: binaries/client build-extension-types build-extensions
|
||||
rm %APPDATA%/Lens
|
||||
yarn build:win
|
||||
yarn integration
|
||||
|
||||
|
||||
@ -8,7 +8,6 @@ import { AbortController } from "abort-controller";
|
||||
|
||||
interface AppTestingPaths {
|
||||
testingPath: string,
|
||||
libraryPath: string,
|
||||
}
|
||||
|
||||
function getAppTestingPaths(): AppTestingPaths {
|
||||
@ -16,17 +15,14 @@ function getAppTestingPaths(): AppTestingPaths {
|
||||
case "win32":
|
||||
return {
|
||||
testingPath: "./dist/win-unpacked/Lens.exe",
|
||||
libraryPath: path.join(process.env.APPDATA, "Lens"),
|
||||
};
|
||||
case "linux":
|
||||
return {
|
||||
testingPath: "./dist/linux-unpacked/kontena-lens",
|
||||
libraryPath: path.join(process.env.XDG_CONFIG_HOME || path.join(process.env.HOME, ".config"), "Lens"),
|
||||
};
|
||||
case "darwin":
|
||||
return {
|
||||
testingPath: "./dist/mac/Lens.app/Contents/MacOS/Lens",
|
||||
libraryPath: path.join(process.env.HOME, "Library/Application\ Support/Lens"),
|
||||
};
|
||||
default:
|
||||
throw new TypeError(`platform ${process.platform} is not supported`);
|
||||
@ -44,8 +40,6 @@ export function describeIf(condition: boolean) {
|
||||
export function setup(): AppConstructorOptions {
|
||||
const appPath = getAppTestingPaths();
|
||||
|
||||
fse.removeSync(appPath.libraryPath); // remove old install config
|
||||
|
||||
return {
|
||||
path: appPath.testingPath,
|
||||
args: [],
|
||||
|
||||
Loading…
Reference in New Issue
Block a user