-
Notifications
You must be signed in to change notification settings - Fork 12
Visual Studio Code Proposal #264
Open
patel385
wants to merge
2
commits into
master
Choose a base branch
from
vs-code-justification
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,120 @@ | ||
| ## Visual Studio Code Proposal | ||
|
|
||
|
|
||
| ### Description | ||
|
|
||
| This is a proposal to add the `Visual Studio Code` and it's `remote development (SSH)` capabilities in a `Census Environment`. Proposed solution is to be used against `IEBCloud Server`. | ||
|
|
||
| ### What is Visual Studio Code? | ||
|
|
||
| It is an `IDE` developed and backed by Microsoft. It is on the `approved software` list for Census and allowed to be used on Census PC. | ||
|
|
||
| [Visual Studio Code Website](https://code.visualstudio.com/) | ||
|
|
||
| ### What is a Visual Studio Code's Remote Development using SSH? | ||
|
|
||
| The Visual Studio Code Remote - SSH extension allows you to `open a remote folder` on any remote machine, virtual machine, or container with a running SSH server and take full advantage of VS Code's feature set. Once connected to a server, you can interact with files and folders anywhere on the remote filesystem. | ||
|
|
||
| :fire: `No source code needs to be on your local machine` :fire: to gain these benefits since the extension runs commands and other extensions directly on the remote machine | ||
|
|
||
| This lets VS Code provide a local-quality development experience - including :clap: `full IntelliSense (completions), code navigation, and debugging` :clap: - regardless of where your code is hosted. | ||
|
|
||
| [Remote Development Guide For Visual Studio Code](https://code.visualstudio.com/docs/remote/ssh) | ||
|
|
||
| ### What do we use now? | ||
|
|
||
| At `Census`, IEB AWS team uses `IEBCloud - a linux instance` for developing and testing `infrastructure-as-a-code (IaC)`. We use `Reflection SSH client` to connect to IEBCloud. | ||
|
|
||
| On the server we use `VI / VIM` to write the `infrastructure code`. What is `VI / VIM`? It's the `ubiquitous text editor i.e. - present, appearing or found everywhere`. It's a text editor, but Linux Enthusiast say `it's more than an editor`. :white_check_mark: Agreed, but not without a deep customization. It is `keyboard heavy`. For almost everything you have to setup `key combinations`. And mind it you have to :brain: remember :brain: `key combinations` until you are `savvy enough` to roam and navigate comfortably in VIM. | ||
|
|
||
| Can `VIM behave` like an `IDE`? Sure, but not without a `deep customization`. By customization it means, `find, install and configure plugins`. | ||
|
|
||
| This equates to `practice, a learning curve` and most importantly `man hours` before you can master it. | ||
|
|
||
|
|
||
| ### Why add Visual Studio Code? | ||
|
|
||
| It's an IDE. It's sole purpose is to author and debug code. Used by `14 million` developers and counting! Out-of-the-box features supported by `Visual Studio Code` are, | ||
|
|
||
| - Grid Layout (2 / 3 columns), which allows easy file navigation | ||
| e.g. File Explorer (left panel), Content Editor (center panel), Terminal (bottom panel) | ||
| - Syntax Highlighting | ||
| - Auto-complete with Code IntelliSense | ||
| - Built-in `undo stack` | ||
| - Easy code navigation with minimap | ||
| - Built-in Git support | ||
| - Wide range of language support, just to name a few are...with complete syntax highlighting, IntelliSense and formatting. | ||
| - python, | ||
| - hcl (terraform), | ||
| - javascript, | ||
| - golang, | ||
| - shell/bash, | ||
| - c++, | ||
| - c#, | ||
| - Java, | ||
| - PHP, | ||
| - R | ||
| - HTML / CSS / SCSS | ||
| - powershell, | ||
| - TypeScript, | ||
| - Ruby | ||
| - Side by side code editing. Open as many editors and stack them vertically or horizontally. | ||
| - Built-in command line terminal | ||
| - Built-in README rendering | ||
| - Sticky scroll | ||
| - Built-in explorer to browse files and folders | ||
| - Easy file management | ||
| - Easy Search and Replace | ||
| - Open multiple files in separate tabs with in same window (like Chrome Tabs) | ||
| - Command Palette for sleuths of built-in commands | ||
| - Single-click preview mode | ||
| - Built-in key bindings (for `linux enthusiast`) | ||
|
|
||
| **And then there are extensions** | ||
|
|
||
| At `Census`, `terraform, shell scripts and python` are used predominantly. `Visual Studio Code` has extensions for each to improve the tooling around a given language. `Hashicorp` has an official Terraform Extension for `Visual Studio Code` which offers, | ||
|
|
||
| - IntelliSense | ||
| - Syntax Validation | ||
| - Syntax Highlighting | ||
| - Code Navigation | ||
| - Code Snippets | ||
| - Module Explorer | ||
| - Terraform commands | ||
|
|
||
| [HashiCorp Terraform Extension](https://marketplace.visualstudio.com/items?itemName=HashiCorp.terraform) | ||
|
|
||
| **Few more terraform extensions...** | ||
|
|
||
| - [infracost](https://github.com/infracost/vscode-infracost): Cloud agnostic cost estimates on cloud resources as you code. Right in your editor. | ||
| - [terraform-docs](https://marketplace.visualstudio.com/items?itemName=DerekCAshmore.terraform-docs): Generate terraform documentation from your IDE | ||
| - [tfsec](https://github.com/aquasecurity/tfsec): A static analysis security scanner for your Terraform Code that discovers problems with your infrastructure before hackers do. | ||
|
|
||
| **And top productivity booster extensions...pick and choose** | ||
|
|
||
| - **[Remote - SSH](https://code.visualstudio.com/docs/remote/ssh-tutorial):** allows an SSH server as your development environment. Run `commands on a remote server from the IDE` | ||
| - **[Prettier](https://prettier.io/):** A code formatter. Standardizes code formatting across the team. | ||
| - **[GitLens](https://www.gitkraken.com/gitlens):** See who, why and how lines of code have changed over time. Visual file history in the editor. Commit graphs. | ||
| - **[Indent-Rainbow](https://marketplace.visualstudio.com/items?itemName=oderwat.indent-rainbow):** colorizes the indentation of your code, alternating colors at every step. Very useful with large files especially `Yaml / Json`. | ||
| - **[TODO Highlights](https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight):** Highlights TODO comments in codebase | ||
| - **[Peacock](https://marketplace.visualstudio.com/items?itemName=johnpapa.vscode-peacock):** Color-code `Visual Studio Workspaces` for different projects | ||
| - **[Better Comments](https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments):** Enhance code comments with colors and formatting | ||
| - **[Bookmarks](https://marketplace.visualstudio.com/items?itemName=alefragnani.Bookmarks):** Quickly add and navigate bookmarks within code | ||
| - **[Python Snippets](https://marketplace.visualstudio.com/items?itemName=cstrap.python-snippets):** Built-in snippets for common python code | ||
| - **[ShellCheck](https://marketplace.visualstudio.com/items?itemName=timonwong.shellcheck):** A shell script static analysis tool. | ||
| - **[Shell-Format](https://marketplace.visualstudio.com/items?itemName=foxundermoon.shell-format):** A formatter for shell scripts, Dockerfile, gitignore, dotenv, /etc/hosts | ||
|
|
||
| For `Linux Enthusiast`, it has a full support of `keyboard bindings`. In other words, it has best of both worlds. Apart from `Visual Studio Code`, `JetBrains` shares IDE market targeted by languages. | ||
|
|
||
|
|
||
| ### This is a request and not a debate | ||
|
|
||
| This is a proposal to `add` and not `replace`. There is `no one size fits all`. Every developer is different. Has preferred `toolset`. Has deep customizations to their likings. We are not asking to run `Visual Studio Code` on the server. Instead, use it's built-in `SSH capabilities` to increase the productivity, development workflow and take advantage of all the bells / whistles provided by the IDE - the code editor. | ||
|
|
||
|
|
||
| # CHANGELOG | ||
|
|
||
| * 1.0.0 -- 2024-02-02 | ||
| - ritesh | ||
|
|
||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
~/.vscode/and~/.vscode-server/folders will do quickly. In order to fix that, add to your vscode settings.json ->