@@ -5,6 +5,7 @@ import { commands, ProgressLocation, window } from "vscode";
55import { createPlugin } from "../plugins.ts" ;
66import {
77 checkIsAuthenticated ,
8+ checkIsLicenseValid ,
89 requestAuthentication ,
910 saveAuthToken ,
1011} from "../utils/authenticate.ts" ;
@@ -121,8 +122,6 @@ export default createPlugin(
121122 progress . report ( {
122123 message :
123124 "Waiting for authentication response from the browser..." ,
124- // message: "Waiting for browser response...",
125- // message: "Waiting for authentication response...",
126125 } ) ;
127126 const { authToken } = await minDelay (
128127 requestAuthentication ( context , cancellationToken ) ,
@@ -145,7 +144,6 @@ export default createPlugin(
145144
146145 /////////////////////////////////////////////////////////////////////
147146 progress . report ( {
148- // message: "Authenticating...",
149147 message : "Authenticating to file..." ,
150148 } ) ;
151149 await minDelay ( saveAuthToken ( authToken , outputChannel ) ) ;
@@ -167,6 +165,21 @@ export default createPlugin(
167165 }
168166 }
169167
168+ /////////////////////////////////////////////////////////////////////
169+ progress . report ( { message : "Checking LocalStack license..." } ) ;
170+ const licenseIsValid = await minDelay (
171+ checkIsLicenseValid ( outputChannel ) ,
172+ ) ;
173+ if ( licenseIsValid ) {
174+ progress . report ( { message : "License verified succesfully..." } ) ;
175+ } else {
176+ progress . report ( {
177+ message :
178+ "License is not valid or not assigned, please check License settings page..." ,
179+ } ) ;
180+ commands . executeCommand ( "localstack.openLicensePage" ) ;
181+ }
182+
170183 /////////////////////////////////////////////////////////////////////
171184 progress . report ( {
172185 message : "Configuring AWS profiles..." ,
0 commit comments