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
|
.PHONY: integration-linux
|
||||||
integration-linux: binaries/client build-extension-types build-extensions
|
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 build:linux
|
||||||
yarn integration
|
yarn integration
|
||||||
|
|
||||||
.PHONY: integration-mac
|
.PHONY: integration-mac
|
||||||
integration-mac: binaries/client build-extension-types build-extensions
|
integration-mac: binaries/client build-extension-types build-extensions
|
||||||
|
rm ${HOME}/Library/Application\ Support/Lens
|
||||||
yarn build:mac
|
yarn build:mac
|
||||||
yarn integration
|
yarn integration
|
||||||
|
|
||||||
.PHONY: integration-win
|
.PHONY: integration-win
|
||||||
integration-win: binaries/client build-extension-types build-extensions
|
integration-win: binaries/client build-extension-types build-extensions
|
||||||
|
rm %APPDATA%/Lens
|
||||||
yarn build:win
|
yarn build:win
|
||||||
yarn integration
|
yarn integration
|
||||||
|
|
||||||
|
|||||||
@ -8,7 +8,6 @@ import { AbortController } from "abort-controller";
|
|||||||
|
|
||||||
interface AppTestingPaths {
|
interface AppTestingPaths {
|
||||||
testingPath: string,
|
testingPath: string,
|
||||||
libraryPath: string,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function getAppTestingPaths(): AppTestingPaths {
|
function getAppTestingPaths(): AppTestingPaths {
|
||||||
@ -16,17 +15,14 @@ function getAppTestingPaths(): AppTestingPaths {
|
|||||||
case "win32":
|
case "win32":
|
||||||
return {
|
return {
|
||||||
testingPath: "./dist/win-unpacked/Lens.exe",
|
testingPath: "./dist/win-unpacked/Lens.exe",
|
||||||
libraryPath: path.join(process.env.APPDATA, "Lens"),
|
|
||||||
};
|
};
|
||||||
case "linux":
|
case "linux":
|
||||||
return {
|
return {
|
||||||
testingPath: "./dist/linux-unpacked/kontena-lens",
|
testingPath: "./dist/linux-unpacked/kontena-lens",
|
||||||
libraryPath: path.join(process.env.XDG_CONFIG_HOME || path.join(process.env.HOME, ".config"), "Lens"),
|
|
||||||
};
|
};
|
||||||
case "darwin":
|
case "darwin":
|
||||||
return {
|
return {
|
||||||
testingPath: "./dist/mac/Lens.app/Contents/MacOS/Lens",
|
testingPath: "./dist/mac/Lens.app/Contents/MacOS/Lens",
|
||||||
libraryPath: path.join(process.env.HOME, "Library/Application\ Support/Lens"),
|
|
||||||
};
|
};
|
||||||
default:
|
default:
|
||||||
throw new TypeError(`platform ${process.platform} is not supported`);
|
throw new TypeError(`platform ${process.platform} is not supported`);
|
||||||
@ -44,8 +40,6 @@ export function describeIf(condition: boolean) {
|
|||||||
export function setup(): AppConstructorOptions {
|
export function setup(): AppConstructorOptions {
|
||||||
const appPath = getAppTestingPaths();
|
const appPath = getAppTestingPaths();
|
||||||
|
|
||||||
fse.removeSync(appPath.libraryPath); // remove old install config
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
path: appPath.testingPath,
|
path: appPath.testingPath,
|
||||||
args: [],
|
args: [],
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user