My favourite editors: ST, VSC
For Mac OS & Win OS
- Add to terminal source
1. Open VSC & type `cmd+shift+p`
2. Type "Shell" & select 'Shell Command : Install code in PATH'
3. Use `$ code <project-folder-name>`
- For permanence, follow this:
- Open profile in
$ subl ~/.zprofile
- Add this line
# install code on terminal export PATH="/Applications/Visual Studio Code.app/Contents/Resources/app/bin:$PATH" OR alias code="open -a /Applications/Visual\ Studio\ Code.app"
$ source ~/.zprofile
- Now, use
$ code <folder_or_file_path>
from terminal
- Open profile in
In macOS, I can get the list of packages here: ~/.vscode/extensions
in local PC.
last updated on 17-06-2022
Expand:
aaron-bond.better-comments-3.0.0
adpyke.codesnap-1.3.4
ajshort.include-autocomplete-0.0.4
akamud.vscode-theme-onedark-2.2.3
akamud.vscode-theme-onelight-2.2.3
appland.appmap-0.31.0
appland.appmap-0.31.1
azemoh.one-monokai-0.5.0
bierner.markdown-mermaid-1.14.2
bierner.markdown-preview-github-styles-1.0.1
bungcip.better-toml-0.3.2
chrisdias.vscode-opennewinstance-0.0.12
christian-kohler.npm-intellisense-1.4.2
christian-kohler.path-intellisense-2.8.1
christophwolff.sublime-oceanic-after-next-theme-0.0.2
chrisvltn.vs-code-semicolon-insertion-0.0.6
contractshark.solidity-lang-1.4.0
cschlosser.doxdocgen-1.4.0
cssho.vscode-svgviewer-2.0.0
dakshmiglani.hex-to-rgba-1.0.0
davidanson.vscode-markdownlint-0.47.0
dbaeumer.vscode-eslint-2.2.2
dendron.dendron-paste-image-1.1.0
dunstontc.vscode-rust-syntax-0.0.32
eamodio.gitlens-12.1.1
eg2.vscode-npm-script-0.3.25
ericadamski.carbon-now-sh-1.2.0
esbenp.prettier-vscode-9.5.0
fabiospampinato.vscode-markdown-todo-1.1.1
fabiospampinato.vscode-todo-plus-4.18.4
felipe-mendes.slack-theme-1.9.17
formulahendry.auto-close-tag-0.5.14
gimenete.github-linker-0.2.5
gordonlarrigan.vscode-kanbn-0.11.0
grapecity.gc-excelviewer-4.2.55
gruntfuggly.calendar-0.0.13
gruntfuggly.mermaid-export-0.0.8
haaleo.timing-2.7.1
hediet.vscode-drawio-1.6.4
izaxon.todo-0.1.0
jebbs.plantuml-2.17.3
jeff-hykin.better-cpp-syntax-1.15.18
jgclark.vscode-todo-highlight-2.0.4
jithurjacob.nbpreviewer-1.2.2
joaompinto.vscode-graphviz-0.0.6
josetr.cmake-language-support-vscode-0.0.4
jrtools.mariana-1.0.8
juanblanco.solidity-0.0.139
kelvin.vscode-sshfs-1.25.0
kevinrose.vsc-python-indent-1.17.0
llvm-vs-code-extensions.vscode-clangd-0.1.17
maximetinu.identical-sublime-monokai-csharp-theme-colorizer-1.1.0
mechatroner.rainbow-csv-2.4.0
mikestead.dotenv-1.0.1
mkloubert.vscode-kanban-1.33.0
ms-azuretools.vscode-docker-1.22.0
ms-dotnettools.vscode-dotnet-runtime-1.5.0
ms-python.python-2022.8.0
ms-python.vscode-pylance-2022.6.30
ms-toolsai.jupyter-2022.5.1001601848
ms-toolsai.jupyter-keymap-1.0.0
ms-toolsai.jupyter-renderers-1.0.8
ms-toolsai.vscode-jupyter-powertoys-0.0.3
ms-vscode-remote.remote-containers-0.238.2
ms-vscode-remote.remote-ssh-0.82.1
ms-vscode-remote.remote-ssh-0.82.1.vsix
ms-vscode-remote.remote-ssh-edit-0.80.0
ms-vscode-remote.remote-wsl-0.66.3
ms-vscode.cmake-tools-1.11.26
ms-vscode.cpptools-1.10.7-darwin-arm64
ms-vscode.cpptools-extension-pack-1.2.0
ms-vscode.cpptools-themes-1.0.0
ms-vscode.hexeditor-1.9.7
ms-vscode.js-debug-companion-1.0.18
ms-vscode.references-view-0.0.89
ms-vscode.sublime-keybindings-4.0.10
mythx.mythxvsc-0.7.21
naumovs.color-highlight-2.5.0
njpwerner.autodocstring-0.6.1
nomicfoundation.hardhat-solidity-0.4.3
perkovec.emoji-1.0.1
pkief.material-icon-theme-4.18.1
royaction.color-manager-0.7.5
rust-lang.rust-analyzer-0.3.1099-darwin-arm64
rust-lang.rust-analyzer-0.3.1107-darwin-arm64
ryu1kn.partial-diff-1.4.3
smh.eosio-0.0.1
softwaredotcom.swdc-vscode-2.6.31
softwaredotcom.swdc-vscode-2.6.32
streetsidesoftware.code-spell-checker-2.2.5
supperchong.pretty-json-0.0.4
tabnine.tabnine-vscode-3.5.58
tabnine.tabnine-vscode-3.5.59
tintinweb.ethereum-security-bundle-0.0.6
tintinweb.graphviz-interactive-preview-0.3.0
tintinweb.solidity-metrics-0.0.20
tintinweb.solidity-visual-auditor-0.1.2
tintinweb.vscode-ethover-0.0.7
tintinweb.vscode-inline-bookmarks-0.0.26
tintinweb.vscode-lll-0.0.7
tintinweb.vscode-solidity-flattener-0.0.11
tintinweb.vscode-solidity-language-0.0.6
tintinweb.vscode-vyper-0.0.13
tomoki1207.pdf-1.2.0
trailofbits.slither-vscode-0.0.7
twxs.cmake-0.0.17
tyriar.luna-paint-0.15.0
tyriar.vscode-terminal-here-0.2.4
visualstudioexptteam.vscodeintellicode-1.2.21
vitelabs.soliditypp-0.7.11
vitelabs.solppdebugger-0.2.5
wakatime.vscode-wakatime-18.1.6
yzhang.markdown-all-in-one-3.4.3
zainchen.json-2.0.2
This is for MacOS
-
- pre-requisite: install
cppcheck
using$ brew install cppcheck
. Try$ cppcheck
command on terminal - open the global settings cmd+, >> "Extensions" >> "C/C++ Lint configuration" >> untick these:
Flawfinder: Enable Flexelint: Enable Lizard: Enable
which looks like this
- pre-requisite: install
-
- Refer to its usage section
-
ES Lint: Linting for JS, TS
-
- For C/C++ include directive
-
- Activate this
-
- Refer "Usage"
-
Sublime Text Keymap and Settings Importer
- This would enable to work with keyboard shortcuts used in ST
-
- cmd+shift+p >> "Open Keyboard Shortcuts (Default)" >> Search for 'semicolon' >> Toggle the 2 shortcut keys from cmd+/ & cmd+shift+/ to cmd+; & ctrl+shift+;
- There would be another duplicate usage of this keyboard shortcut cmd+shift+;. Change that to some other shortcut key.
-
- cmd+shift+p >> "Open Keyboard Shortcuts (Default)" >> Search for 'terminal here' >> set ctrl+shift+t as shortcut key
-
Work with WSL Ubuntu Server (Applicable for Win OS)
First install the Sublime Text Keymap and Settings Importer, then follow this shortcut keys along with this:
- cmd+, - Open preferences (global)
- cmd+k+t, ctrl+t - change the color theme
- cmd+shift+p - open the command palette
- cmd+shift+c - open the terminal in the directory of the opened file
- ctrl+` - toggle the terminal (integrated)
- ctrl+l - select multiple lines
- ctrl+shift+l - edit multiple lines at a time
- cmd+k,f - close the opened folder
- cmd+k+b - toggle the explorer
- cmd+shift+k - delete the line cursor is at
- press cmd & hold - Edit multiple lines at different line no. simultaneously.
- cmd+opt+1 - Only one screen
- cmd+opt+2 - 2 screens side by side. In order to have 3 screens, just select one file opened & then press this shortcut key.
- ctrl+g - Go to a line
- cmd+shift+f - Find all references of a function in entire project files.
- opt+click - Go to the file, function, folder directly
- ctrl+w - Switch to workspace/window
- cmd+shift+. - View a navigation pane for a file
- opt+ 🔼/🔽 - Keeping the cursor on a line, use this move the line up or down
- cmd+f - find in the current file
- cmd+shift+f - find in the current workspace
- cmd+opt+f - Replace in the current file
- ctrl+spacebar - give suggestions at any red color cursor point
- cmd+shift+e - show the active file in the explorer
- cmd+k, s - Here, save file without formatting. Normally, if the formatter is enabled for the file extension type in the VSCode Settings, then when doing cmd+s, the file is saved with formatting automatically.
- Open sub-folder in new window using this package
First install the Sublime Text Keymap and Settings Importer, then follow this shortcut keys along with this:
- ctrl+k+t, ctrl+t - change the color theme
- ctrl+shift+p - open the command palette
- ctrl+` - toggle the terminal
- ctrl+k,f</kbd - close the opened folder
- ctrl+k+b</kbd - toggle the explorer
- ctrl+shift+k</kbd - delete the line cursor is at
- press ctrl & hold - Edit multiple lines at different line no. simultaneously.
- In VSCode, 2 ways to be dependent on settings for a language:
- global: cmd+shift+p >> "Preferences: Open Settings"
- local: create a language properties for a repository like "c_cpp_properties.json" inside ".vscode/" folder.
NOTE: By default, the local settings (if defined) supersedes global settings.
In VSCode, select the default formatter with this package for all files (sol, ts, js, md, py, java, cpp)
Procedure:
- Open Settings
- type 'save format' >> tick the "Editor: Format on Save"
- type 'formatter' >> set the "Editor: Default Formatter" to Prettier (by esbenp....)
- type 'solidity formatter' >> set the "Solidity: Formatter" from
none
toprettier
- Now, on saving any solidity (
*.sol
) file, it will automatically format.
- Look at the packages to be installed above.
- Maintain this settings in the "Preferences: Open Settings" file (get by typing after pressing key cmd+,).
"C_Cpp.workspaceSymbols": "All",
"c-cpp-flylint.flawfinder.enable": false,
"c-cpp-flylint.flexelint.enable": false,
"c-cpp-flylint.lizard.enable": false,
"cmake.configureOnOpen": true,
"C_Cpp.errorSquiggles": "Disabled",
"C_Cpp.default.cppStandard": "c++17",
"C_Cpp.default.includePath": [
"${workspaceFolder}/**",
"/Library/Developer/CommandLineTools/usr/include",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/libc",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/libcxx",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/capi",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/contracts",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/core",
"/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/native"
],
// "c-cpp-flylint.includePaths": [
// "${workspaceFolder}/**",
// "/Library/Developer/CommandLineTools/usr/include",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/libc",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/libcxx",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/capi",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/contracts",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/core",
// "/usr/local/Cellar/eosio.cdt/1.8.1/opt/eosio.cdt/include/eosiolib/native"
// ],
"include-autocomplete.extensions": [
"",
".h",
".hpp",
".hxx",
".cpp"
],
Commented "c-cpp-flylint.includePaths" because it is not linting the imp. ones.
- Use this compiler based on OS:
- Mac:
clang
- Linux (using WSL):
g++
- Mac:
- In Mac,
clang
uses this directory for compiling: "/Library/Developer/CommandLineTools/usr/include/". - In order to put some custom lib or folder like
boost
, download the folder from here & paste into this directory: "/Library/Developer/CommandLineTools/usr/include/"
- TODO also looks in good color like this
- More config commands: https://code.visualstudio.com/docs/cpp/customize-default-settings-cpp
- Add the static analyzer package above.
- Look at the packages to be installed above.
- ESLint package automatically ensures linting on typescript in vscode
- @pre
- First install the compiler as per this
- @pre
- Add the packages above.
- Look at the packages to be installed above.
- Python (by Microsoft) provides linting, suggestion
- Look at the packages to be installed above.
How to manage todo inside VSC
- cmd+enter / opt+enter: toggle TODO
- opt+s: toggle start of task
- opt+d: toggle end of task
- cmd+shift+p: open command palette & then:
- "Todo: Toggle Cancelled" to cancel (the task on which the cursor was)
- "TODO-highlight: List highlighted annotations" to show all the TODOs in the workspace.
- Look at the packages to be installed above.