Note
Highlights information that users should take into account, even when skimming.
> [!NOTE]
> Highlights information that users should take into account, even when skimming.
Tip
Optional information to help a user be more successful.
Note
Highlights information that users should take into account, even when skimming.
> [!NOTE]
> Highlights information that users should take into account, even when skimming.
Tip
Optional information to help a user be more successful.
Sometimes, when using Windows WSL to edit projects, Git will report a file permissions change.
You cannot fix, change, remove or do anything with these files and it causes issues when pulling.
Just do this:
git config core.filemode falseIf, like me, you create new DotNet projects using the same layout and options; the following script should help.
Type $profile in your Powershell Windows Terminal and edit the file at the path given by putting the following code in:
# ---------- dot net new simple alias for project creation
function Show-Menu {
param (
[string]$Title
)| // when T is any|unknown, Y is returned, otherwise N | |
| type IsAnyUnknown<T, Y, N> = unknown extends T ? Y : N; | |
| // when T is never, Y is returned, otherwise N | |
| type IsNever<T, Y = true, N = false> = [T] extends [never] ? Y : N; | |
| // when T is a tuple, Y is returned, otherwise N | |
| // valid tuples = [string], [string, boolean], | |
| // invalid tuples = [], string[], (string | number)[] |
Unfortunately nvm use on Windows does not change the node version to that specified in the .nvmrc file as its not supported on nvm for Windows: coreybutler/nvm-windows#388
So the easiest solution to this is to use a simple Powershell command that performs an approximation of the command as follows:
nvm use $(Get-Content .nvmrc).replace( 'v', '' );
However, thats a bit awkward and we can do a bit more so instead, we can create an 'alias' to a function that calls the command instead:
function callnvm() {
| #!/bin/sh | |
| # Config options | |
| min_length=4 | |
| max_length=50 | |
| types=("feat" "fix" "perf") | |
| # End config options |
| { | |
| // Use IntelliSense to learn about possible attributes. | |
| // Hover to view descriptions of existing attributes. | |
| // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | |
| // To find location of yo folder type: | |
| // 'which yo' | |
| // and then replace the end segments '/npm/yo' with '/npm/node_modules/yo/lib/cli.js' | |
| "version": "0.2.0", |
| using System; | |
| using System.Collections.Generic; | |
| using System.Web; | |
| using System.Web.Mvc; | |
| using System.Web.Optimization; | |
| using System.Web.Routing; | |
| using Microsoft.Extensions.DependencyInjection; | |
| using WebApplication16; | |
| using WebApplication16.Controllers; |
| REG ADD HKLM\SYSTEM\CurrentControlSet\Services\W3SVC /v SvcHostSplitDisable /t REG_DWORD /d 1 /f | |
| REG ADD HKLM\SYSTEM\CurrentControlSet\Services\WAS /v SvcHostSplitDisable /t REG_DWORD /d 1 /f |