Skip to content

Commit

Permalink
[ide] added VS Code "Insiders" IDE variant
Browse files Browse the repository at this point in the history
  • Loading branch information
JanKoehnlein authored and roboquat committed Aug 10, 2021
1 parent f74fbca commit 7826291
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 5 deletions.
10 changes: 9 additions & 1 deletion chart/templates/server-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,13 @@ functions:
group: inWorkspaceUserAction
{{- end -}}

{{- define "stable-image-full" -}}
{{- $ := .root -}}
{{- $gp := .gp -}}
{{- $comp := .comp -}}
{{ template "gitpod.comp.imageRepo" . }}:{{ $comp.stableVersion }}
{{- end -}}

{{ $comp := .Values.components.server -}}
{{- $this := dict "root" . "gp" $.Values "comp" $comp -}}
{{- $thisWorkspace := dict "root" . "comp" .Values.components.workspace -}}
Expand Down Expand Up @@ -157,7 +164,8 @@ spec:
- name: WORKSPACE_DEFAULT_IMAGE
value: "{{ template "gitpod.comp.imageFull" (dict "root" . "gp" $.Values "comp" .Values.components.workspace.defaultImage) }}"
- name: IDE_IMAGE_ALIASES
value: {{ (dict "code" (include "gitpod.comp.imageFull" (dict "root" . "gp" $.Values "comp" .Values.components.workspace.codeImage))) | toJson | quote }}
value: {{ (dict "code-latest" (include "gitpod.comp.imageFull" (dict "root" . "gp" $.Values "comp" .Values.components.workspace.codeImage))
"code" (include "stable-image-full" (dict "root" . "gp" $.Values "comp" .Values.components.workspace.codeImage))) | toJson | quote }}
{{- if $comp.blockNewUsers }}
- name: BLOCK_NEW_USERS
value: {{ $comp.blockNewUsers | quote }}
Expand Down
1 change: 1 addition & 0 deletions chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,7 @@ components:
imageName: "ide/theia"
codeImage:
imageName: "ide/code"
stableVersion: "commit-0941a0805dc3c7345c45bd926317eaf045d4b7fb"
supervisor:
imageName: "supervisor"
dockerUp:
Expand Down
17 changes: 13 additions & 4 deletions components/dashboard/src/settings/Preferences.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import vscode from '../images/vscode.svg';
import { PageWithSubMenu } from "../components/PageWithSubMenu";
import settingsMenu from "./settings-menu";
import AlertBox from "../components/AlertBox";
import Tooltip from "../components/Tooltip";

type Theme = 'light' | 'dark' | 'system';

Expand Down Expand Up @@ -54,13 +55,21 @@ export default function Preferences() {
</AlertBox>
<div className="mt-4 space-x-4 flex">
<SelectableCard className="w-36 h-40" title="VS Code" selected={defaultIde === 'code'} onClick={() => actuallySetDefaultIde('code')}>
<div className="flex-grow flex justify-center items-center">
<img className="w-16 filter-grayscale" src={vscode}/>
<div className="flex justify-center mt-3">
<img className="w-16 filter-grayscale self-center" src={vscode} />
</div>
</SelectableCard>
<Tooltip content={'Early access version, still subject to testing.'} >
<SelectableCard className="w-36 h-40" title="VS Code" selected={defaultIde === 'code-latest'} onClick={() => actuallySetDefaultIde('code-latest')}>
<div className="flex justify-center mt-3">
<img className="w-16 filter-grayscale self-center" src={vscode} />
</div>
<span className="mt-2 ml-2 self-center rounded-xl py-0.5 px-2 text-sm bg-orange-100 text-orange-700 dark:bg-orange-600 dark:text-orange-100 font-semibold">LATEST</span>
</SelectableCard>
</Tooltip>
<SelectableCard className="w-36 h-40" title="Theia" selected={defaultIde === 'theia'} onClick={() => actuallySetDefaultIde('theia')}>
<div className="flex-grow flex justify-center items-center">
<img className="w-16 dark:filter-invert" src={theia}/>
<div className="flex justify-center mt-3">
<img className="w-16 h-16 dark:filter-invert self-center" src={theia} />
</div>
</SelectableCard>
</div>
Expand Down

0 comments on commit 7826291

Please sign in to comment.