visual-studio-code

VSCode Asp.Net core command line arguments when debugging?

巧了我就是萌 提交于 2021-02-08 09:07:28
问题 Just been reading this article from Scott Allen. The approach to specify command line arguments to .net core seems intersing, but how do we pass those arguments from VS Code when running with debugger (Normally using F5 command if launch.json is setup)? e.g dotnet run dropdb migratedb seeddb 回答1: Copying over answer from comment In your launch.json , try adding: "args": ["dropdb", "migratedb", "seeddb"] to the target launch configuration. 来源: https://stackoverflow.com/questions/41189755

terminal.integrated.env.windows for Integrated Terminal

拥有回忆 提交于 2021-02-08 08:21:42
问题 I'm trying to set variable before start the Integrated Terminal User Setting: { "terminal.integrated.env.windows": { "foo": "bar" } } Then View > Integrated Terminal Windows PowerShell Copyright (C) 2016 Microsoft Corporation. All rights reserved. PS C:\bar> echo $foo PS C:\bar> It's seem not work, It's bug or I'm wrong? VSCode Version: 1.16.1 PS: Already seem Set global $PATH environment variable in VS Code 回答1: Finally, yume-chan answer by question in Ref: https://github.com/Microsoft

terminal.integrated.env.windows for Integrated Terminal

坚强是说给别人听的谎言 提交于 2021-02-08 08:20:25
问题 I'm trying to set variable before start the Integrated Terminal User Setting: { "terminal.integrated.env.windows": { "foo": "bar" } } Then View > Integrated Terminal Windows PowerShell Copyright (C) 2016 Microsoft Corporation. All rights reserved. PS C:\bar> echo $foo PS C:\bar> It's seem not work, It's bug or I'm wrong? VSCode Version: 1.16.1 PS: Already seem Set global $PATH environment variable in VS Code 回答1: Finally, yume-chan answer by question in Ref: https://github.com/Microsoft

how to use beautify for javascript/react?

浪尽此生 提交于 2021-02-08 08:00:37
问题 I have installed Beautify to use it for my react.js code. However, it apparently does not properly beautify the html format in the file. For example, it turns this: into this: Among all the options, which option should I use to fix this ? 回答1: I used to have the same problem. Apparently beautify doesn't support JSX. I uninstalled and instead of it, I installed Prettier, it works great for me. Hope I helped you. 回答2: Just change language mode javascript to javascript react [temporary] VSCode

how to use beautify for javascript/react?

不想你离开。 提交于 2021-02-08 08:00:18
问题 I have installed Beautify to use it for my react.js code. However, it apparently does not properly beautify the html format in the file. For example, it turns this: into this: Among all the options, which option should I use to fix this ? 回答1: I used to have the same problem. Apparently beautify doesn't support JSX. I uninstalled and instead of it, I installed Prettier, it works great for me. Hope I helped you. 回答2: Just change language mode javascript to javascript react [temporary] VSCode

Chang git account on VScode

浪尽此生 提交于 2021-02-08 06:39:38
问题 I just try to push a repo to github , but I get this dialog PS : 4495b is the old account I can't find a way to change it. I tried git config --global --unset credential.helper Reinstall git and reconfigure it Reinstall VScode Any ideas how to refresh the given account? 回答1: If you confirm that git config credential.helper is not set, check first the remote URL with cd /path/to/repo git remote -v If it is an SSH URL, make sure its associated ~/.ssh/id_rsa ( .pub ) are not the private/public

'${workspaceFolder}' can not be resolved. Please open a folder.' on Visual Studio Code

自古美人都是妖i 提交于 2021-02-08 06:33:50
问题 wondering if you could assist. Really challenging in determining a solution to this from my research. Ive downloaded Visual Studio code two weeks ago and has come across an error once I try to debug a file. The file appears to open but once I run the debugger it shows accordingly: '${workspaceFolder}' can not be resolved. Please open a folder. Can't seem to find or replicate a similar solution. I've also tried to reinstall Visual Studio code (no easy feat). I'm trying to at least understand

How can I change the default build output directory in Visual Studio Code

烈酒焚心 提交于 2021-02-08 06:27:38
问题 I'm new to Visual Studio Code. I want to define the output directory in my csproj. I don't know where to change in Visual Studio Code the destination folder to locate the dll files generated. 回答1: VSCode uses dotnet CLI and particularly for building the dotnet build command. Among others, it has the following option -o|--output <OUTPUT_DIRECTORY> Directory in which to place the built binaries. Assuming your building task is defined in .vscode/tasks.json file: { "version": "2.0.0", "tasks": [

How to use “compileOnSave” in VS Code?

青春壹個敷衍的年華 提交于 2021-02-08 05:44:54
问题 Typescript has a configuration option for auto compilation of typescript, as documented here. { "compileOnSave": true, "compilerOptions": { "noImplicitAny" : true } } But simply including this in my tsconfig.json file is not enough to trigger auto compilation. I use MS Visual Studio Code as my IDE. How do I trigger the "compile on save" behavior? 回答1: According to the TypeScript site: "This feature is currently supported in Visual Studio 2015 with TypeScript 1.8.4 and above, and atom

Using Built in Icons for Extension menus

橙三吉。 提交于 2021-02-08 05:36:15
问题 I'd like to reuse the "play" button icon used in the debugger toolbar for a new menu item I'm adding from an extension. Is there a way to set up the icon information in "package.json" to use that existing svg already in VSCode or do I have to supply my own for extensions? 回答1: Yes you can use built-in icons, they are called Codicons. Here is a list of them: https://code.visualstudio.com/api/references/icons-in-labels To use them in your package.json, you will put "icon": "$(iconIdentifier)" .