1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

fix linter complaints

Signed-off-by: Jussi Nummelin <jussi.nummelin@gmail.com>
This commit is contained in:
Jussi Nummelin 2020-06-16 13:05:24 +03:00 committed by Jari Kolehmainen
parent 7178d0534a
commit 84d4535f54
3 changed files with 8 additions and 5 deletions

View File

@ -27,7 +27,7 @@ export class KubeconfigManager {
protected createTemporaryKubeconfig(): string {
ensureDir(this.configDir)
const path = `${this.configDir}/${randomFileName("kubeconfig")}`
let kc = {
const kc = {
clusters: [
{
name: this.cluster.contextName,

View File

@ -11,11 +11,11 @@ export function migration(store: any) {
const kubeConfigBase = path.join(app.getPath("userData"), "kubeconfigs")
ensureDirSync(kubeConfigBase)
let storedClusters = store.get("clusters") as any[]
const storedClusters = store.get("clusters") as any[]
if (!storedClusters) return
console.log("num clusters to migrate: ", storedClusters.length)
for (let cluster of storedClusters ) {
for (const cluster of storedClusters ) {
// TODO Should probably guard this, not to make the whole migration fail if one cluster fails!?
// take the embedded kubeconfig and dump it into a file
const kubeConfigFile = clusterStore.writeEmbeddedKubeConfig(cluster.id, cluster.kubeConfig)

View File

@ -16,8 +16,11 @@
placeholder="Choose a file or drop it here..."
drop-placeholder="Drop file here..."
@input="reloadKubeContexts()"
></b-form-file>
<div class="mt-3">Selected file: {{ file ? file.name : '' }}</div>
/>
<div class="mt-3">
Selected file: {{ file ? file.name : '' }}
</div>
<b-form-select
id="kubecontext-select"