Skip to content

Instantly share code, notes, and snippets.

View danpetitt's full-sized avatar

Dan Petitt danpetitt

View GitHub Profile
@danpetitt
danpetitt / nvmuse.md
Last active January 27, 2025 02:59
Using nvmrc on Windows

Using nvmrc on Windows

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() {
@danpetitt
danpetitt / commit-msg
Created February 21, 2020 22:39
Semantic Release Git Hook
#!/bin/sh
# Config options
min_length=4
max_length=50
types=("feat" "fix" "perf")
# End config options
@danpetitt
danpetitt / launch.json
Created December 11, 2019 15:24
Debug Yeoman Generator using VSCode 2019
{
// 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",

Keybase proof

I hereby claim:

  • I am danpetitt on github.
  • I am coderangerdan (https://keybase.io/coderangerdan) on keybase.
  • I have a public key whose fingerprint is 903F DB11 F61C DA3C 1C44 08A2 1D0A 0A6F 8973 3FF7

To claim this, I am signing this object: