Skip to content

Commit

Permalink
Project import generated by Copybara.
Browse files Browse the repository at this point in the history
GitOrigin-RevId: ab872016554d025f1b75f364acb90a3c8e431923
  • Loading branch information
Copybara Bot authored and fortenforge committed Jan 10, 2024
1 parent 33b3291 commit a9c1962
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 42 deletions.
10 changes: 4 additions & 6 deletions CodeiumVS/LanguageServer/LanguageServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using Microsoft.VisualStudio.Imaging;
using Microsoft.VisualStudio.Shell.Interop;
using Microsoft.VisualStudio.Threading;
using Microsoft.Win32;
using Newtonsoft.Json;
using System.Collections.Generic;
using System.ComponentModel;
Expand All @@ -25,7 +24,7 @@ namespace CodeiumVS;
public class LanguageServer
{
private string _languageServerURL;
private string _languageServerVersion = "1.6.13";
private string _languageServerVersion = "1.6.22";

private int _port = 0;
private Process _process;
Expand All @@ -48,7 +47,7 @@ public async Task InitializeAsync()
{
await ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync();

string ideVersion = "17.0", locale = "en-US";
string ideVersion = "1.6.22";

try
{
Expand Down Expand Up @@ -201,8 +200,7 @@ public async Task SignOutAsync()
/// <returns></returns>
private async Task GetLanguageServerInfoAsync()
{
string extensionBaseUrl = (_package.SettingsPage.ExtensionBaseUrl.Equals("") ? "https://github.com/Exafunction/codeium/releases/download"
: _package.SettingsPage.ExtensionBaseUrl.Trim().TrimEnd('/'));
string extensionBaseUrl = "https://github.com/Exafunction/codeium/releases/download";

if (_package.SettingsPage.EnterpriseMode)
{
Expand Down Expand Up @@ -395,7 +393,7 @@ public async Task PrepareAsync()
}

await ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync();
await _package.LogAsync($"Downloading language server v{_languageServerVersion} from {_languageServerURL}");
await _package.LogAsync($"Downloading language server v{_languageServerVersion}");

// show the downloading progress dialog before starting the thread to make it feels more
// responsive
Expand Down
1 change: 1 addition & 0 deletions CodeiumVS/LanguageServer/Packets.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2662,6 +2662,7 @@ public enum Language
LANGUAGE_NIM = 88,
LANGUAGE_PROLOG = 89,
LANGUAGE_MARKDOWN_INLINE = 90,
LANGUAGE_APEX = 91,
}

[global::ProtoBuf.ProtoContract()]
Expand Down
17 changes: 0 additions & 17 deletions CodeiumVS/SettingsPage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ public class SettingsPage : DialogPage
private bool enterpriseMode;
private string portalUrl = "";
private string apiUrl = "";
private string extensionBaseUrl = "https://github.com/Exafunction/codeium/releases/download";
private bool enableCommentCompletion = true;
private bool enableLanguageServerProxy = false;

Expand Down Expand Up @@ -40,22 +39,6 @@ public string PortalUrl
}
}

[Category("Codeium")]
[DisplayName("Language Server Download URL")]
[Description(
"If you're experiencing network issues with GitHub and can't download the language server, please change this to a GitHub Mirror URL instead. For example: https://gh.api.99988866.xyz/https://github.com/Exafunction/codeium/releases/download")]
public string ExtensionBaseUrl
{
get
{
return extensionBaseUrl;
}
set
{
extensionBaseUrl = value;
}
}

[Category("Codeium")]
[DisplayName("API Url")]
[Description("API Url for Codeium Enterprise. Requires restart.")]
Expand Down
32 changes: 15 additions & 17 deletions CodeiumVS/Windows/ChatToolWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -235,25 +235,28 @@ static uint GetColor(ThemeResourceKey key)
style.textContent = `
body {{
/* window background */
--vscode-editor-background: #{GetColor(CommonControlsColors.ComboBoxBackgroundBrushKey):x8};
--vscode-editor-foreground: #{textColor:x8};
--vscode-sideBar-background: #{GetColor(EnvironmentColors.ToolWindowBackgroundBrushKey):x8};
--vscode-foreground: #{textColor:x8};
--codeium-editor-background: #{GetColor(CommonControlsColors.ComboBoxBackgroundBrushKey):x8};
--codeium-editor-color: #{textColor:x8};
--codeium-chat-background: #{GetColor(EnvironmentColors.ToolWindowBackgroundBrushKey):x8};
--codeium-text-color: #{textColor:x8};
/* user message block */
--vscode-list-activeSelectionBackground: #{GetColor(EnvironmentColors.VizSurfaceSteelBlueMediumBrushKey):x8};
--vscode-list-hoverBackground: #{GetColor(CommonControlsColors.ComboBoxBackgroundHoverBrushKey):x8};
--vscode-list-activeSelectionForeground: #{textColor:x8};
--codeium-message-block-user-background: #{GetColor(EnvironmentColors.VizSurfaceSteelBlueMediumBrushKey):x8};
--codeium-message-block-user-color: #{textColor:x8};
/* bot message block */
--vscode-list-inactiveSelectionBackground: #{GetColor(CommonControlsColors.ComboBoxBackgroundDisabledBrushKey):x8};
--codeium-message-block-bot-background: #{GetColor(CommonControlsColors.ComboBoxBackgroundDisabledBrushKey):x8};
--codeium-message-block-bot-color: #{textColor:x8};
/* textbox input */
--vscode-input-background: #{GetColor(CommonControlsColors.TextBoxBackgroundBrushKey):x8};
--vscode-input-foreground: #{GetColor(CommonControlsColors.TextBoxTextBrushKey):x8};
--vscode-input-placeholderForeground: #{GetColor(CommonControlsColors.TextBoxTextDisabledBrushKey):x8};
--codeium-input-background: #{GetColor(CommonControlsColors.TextBoxBackgroundBrushKey):x8};
--codeium-input-color: #{GetColor(CommonControlsColors.TextBoxTextBrushKey):x8};
--codeium-input-placeholder: #{GetColor(CommonControlsColors.TextBoxTextDisabledBrushKey):x8};
/* hyperlink */
--codeium-link-color: #{GetColor(EnvironmentColors.DiagReportLinkTextBrushKey):x8};
--codeium-link-hover-color: #{GetColor(EnvironmentColors.DiagReportLinkTextHoverColorKey):x8};
/* border */
--vscode-contrastBorder: #{GetColor(CommonDocumentColors.ListItemBorderFocusedBrushKey):x8};
Expand Down Expand Up @@ -285,11 +288,6 @@ static uint GetColor(ThemeResourceKey key)
--vscode-dropdown-background: #{GetColor(EnvironmentColors.DropDownBackgroundBrushKey):x8};
--vscode-dropdown-border: #{GetColor(EnvironmentColors.DropDownBorderBrushKey):x8};
--vscode-dropdown-foreground: #{GetColor(EnvironmentColors.DropDownTextBrushKey):x8};
/* hyperlink */
--vscode-textLink-foreground: #{GetColor(EnvironmentColors.DiagReportLinkTextBrushKey):x8};
--vscode-textLink-activeForeground: #{GetColor(EnvironmentColors.DiagReportLinkTextHoverColorKey):x8};
/* progressbar */
--vscode-progressBar-background: #{GetColor(ProgressBarColors.IndicatorFillBrushKey):x8};
Expand Down
2 changes: 1 addition & 1 deletion CodeiumVS/source.extension.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ internal sealed partial class Vsix
public const string Description =
@"The modern coding superpower: free AI code acceleration plugin for your favorite languages. Type less. Code more. Ship faster.";
public const string Language = "en-US";
public const string Version = "1.6.13";
public const string Version = "1.6.22";
public const string Author = "Codeium";
public const string Tags = "";
}
Expand Down
2 changes: 1 addition & 1 deletion CodeiumVS/source.extension.vsixmanifest
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<PackageManifest Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vsx-schema/2011" xmlns:d="http://schemas.microsoft.com/developer/vsx-schema-design/2011">
<Metadata>
<Identity Id="Codeium.VisualStudio" Version="1.6.13" Language="en-US" Publisher="Codeium" />
<Identity Id="Codeium.VisualStudio" Version="1.6.22" Language="en-US" Publisher="Codeium" />
<DisplayName>Codeium</DisplayName>
<Description xml:space="preserve">The modern coding superpower: free AI code acceleration plugin for your favorite languages. Type less. Code more. Ship faster.</Description>
<MoreInfo>https://www.codeium.com</MoreInfo>
Expand Down

0 comments on commit a9c1962

Please sign in to comment.