Skip to content

Commit

Permalink
new release v2.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
TikouWeb committed Jan 5, 2024
1 parent 53a0e2b commit c325cb8
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 19 deletions.
15 changes: 13 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,20 @@ All notable changes to the "gcp-switch-configuration" extension will be document
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]
## [2.0.3] - 2024-01-05

- Initial release
### Fixed

- Fix configuration rename when name didn't change

### Changed

- Enhance UI and dark/light theme colors
- speedUP configurations switch

### Added

- Auto publish new extension versions to VsCode marketplace

## [2.0.0] - 2023-12-30

Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# GCP Switch Configuration

Simplify your Google Cloud Platform (GCP) experience with the "GCP Switch Configuration" VSCode extension.
Simplify your Google Cloud Platform (GCP) experience with the "GCP Switch Configuration" VSCode extension.

Seamlessly switch between different GCP configurations with just a few clicks!

Expand Down Expand Up @@ -38,9 +38,9 @@ OR

From the dashboard, you can **manage** all your gcp configurations.

**Search for configurations** just like is you were using google cloud platform console.
**Search for configurations** just like if you were using google cloud platform console.

with `ADC.json` link, you Quick access to the `application_default_configuration.json` of the current active configuration.
with `ADC.json` link, you have Quick access to `application_default_configuration.json` of active configuration.

<img src="assets/screenshots/dashboard.png" alt="gcp form" style="width:600px;" />

Expand All @@ -52,7 +52,7 @@ Search for project to attach to you configuration with autocomplete input in the

<img src="assets/screenshots/form.png" alt="gcp form" style="width:600px;" />

### Fully Responsive UI with Dark/Ligh mode
### Fully Responsive UI with Dark/Light mode

<img src="assets/screenshots/responsive.png" alt="gcp form" style="width:600px;" />

Expand Down
4 changes: 3 additions & 1 deletion assets/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ body {
}

body.vscode-light {
--primary-color: #005fb8;

--text-primary-color: rgba(0, 0, 0, 0.87);
--text-secondary-color: rgba(0, 0, 0, 0.6);
--text-disabled-color: rgba(0, 0, 0, 0.38);
Expand Down Expand Up @@ -254,7 +256,6 @@ body.vscode-dark {

.codicon {
font-size: 11px;
font-weight: bold;
}
}
}
Expand All @@ -280,6 +281,7 @@ body.vscode-dark {
top: 70px;
padding: 8px;
border-radius: var(--border-radius-medium);
box-shadow: var(--shadow-1);

.autocomplete-dropdown-item {
display: flex;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "gcp-switch-config",
"displayName": "GCP Switch Configuration",
"description": "Switch gcp configuration with one click just like magic ✨",
"version": "2.0.2",
"version": "2.0.3",
"private": false,
"repository": {
"type": "git",
Expand Down
24 changes: 16 additions & 8 deletions src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,16 @@ const openDashboardPanel = (extensionContext: vscode.ExtensionContext) => {

dashboardPanel.webview.postMessage({ command: "start_loading" });

switchGcpConfig(extensionContext, dashboardPanel, {
name: gcpConfig.name,
account: gcpConfig.properties.core.account,
project: gcpConfig.properties.core.project,
});
switchGcpConfig(
extensionContext,
dashboardPanel,
{
name: gcpConfig.name,
account: gcpConfig.properties.core.account,
project: gcpConfig.properties.core.project,
},
false
);

return;
}
Expand Down Expand Up @@ -165,12 +170,15 @@ const switchGcpConfig = async (
name: GCP_CONFIGURATION["name"];
account: GCP_CONFIGURATION["properties"]["core"]["account"];
project: GCP_CONFIGURATION["properties"]["core"]["project"];
}
},
shouldUpdateGcpConfigProperties = true
) => {
try {
await activateConfig(gcpConfig.name);
await setGcpConfigAccount(gcpConfig.account);
await setGcpConfigProject(gcpConfig.project);
if (shouldUpdateGcpConfigProperties) {
await setGcpConfigAccount(gcpConfig.account);
await setGcpConfigProject(gcpConfig.project);
}

const message = `GCP config switched successfully to [${gcpConfig.name}]`;

Expand Down
2 changes: 1 addition & 1 deletion src/views/components/gcp-topbar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export const gcpTopbar = (gcpConfigurations: GCP_CONFIGURATION[]) => {
<div class="header">
<div id="header-title" style="display: flex; justify-content: flex-start; align-items: center; gap: 3em; flex: 1;">
<div class="gcp-current-configuration">
<p><i class="codicon codicon-check"></i>your active configuration is</p>
<p><i class="codicon codicon-pass-filled"></i>Active</p>
<h2>${gcpActiveConfig?.name}</h2>
</div>
</div>
Expand Down
2 changes: 0 additions & 2 deletions src/views/gcp-config-form.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ export const gcpConfigFormView = ({
width: 420px;
margin: auto auto;
padding: 20px;
height: 100vh;
}
form {
Expand All @@ -47,7 +46,6 @@ export const gcpConfigFormView = ({
border: 1px solid var(--border-color);
background-color: var(--bg-paper);
border-radius: var(--border-radius-medium);
box-shadow: var(--shadow-1);
}
.form-group {
Expand Down

0 comments on commit c325cb8

Please sign in to comment.