Skip to content

Instantly share code, notes, and snippets.

View Nigtellios's full-sized avatar
💃
One kiss is all it takes

Nigtellios Nigtellios

💃
One kiss is all it takes
View GitHub Profile
@Nigtellios
Nigtellios / tut.md
Created July 29, 2023 00:07
[MacOS] Make VSC Writable
  1. Give Full Disk Access to your terminal.
  2. Run sudo chown -R $(whoami) "/Applications/Visual Studio Code.app"
@Nigtellios
Nigtellios / tut.md
Last active August 14, 2023 20:10
[Windows] VSC Isn't recognizing Git repositories

If you're using msys2: microsoft/vscode#4651 (comment)

If not, just try this command: git config --global --add safe.directory '*'

Helped in my case. Cheers.

@Nigtellios
Nigtellios / gist:86d17434dd51d717bbfd0bc21f97d027
Last active August 14, 2023 20:21
Configuring Git Bash Aliases on Windows 11
  1. Install Git for windows (with Git Bash)
  2. Check option "Add profile for Windows Terminal" during installation
  3. After successfull installation create a file .bashrc in your C:\Users<USER>
  4. Populate the file with aliases as follows: alias <NAME>='<COMMAND>' You can also use a multiline aliases like:
<ALIAS>() {
   <COMMAND_1>
 
@Nigtellios
Nigtellios / gist:613915a2e5ab0d311610c2e88132cb66
Last active August 14, 2023 20:23
Adding autocomplete to Git Bash on Windows
  1. Go into your C:\User\<USER> with your terminal.
  2. Run command mkdir ~/bash_completion.d
  3. Run command curl -o ~/bash_completion.d/git https://raw.githubusercontent.com/git/git/master/contrib/completion/git-completion.bash
  4. Run command echo "source ~/bash_completion.d/git" >> ~/.bashrc

Now you can look for completions with TAB.

@Nigtellios
Nigtellios / gist:3ce9832e0140f0a321494fceb405f800
Last active August 14, 2023 20:23
Node-gyp error fix on Windows 11 (does not match this Visual Studio Command Prompt)

If you're getting the following error:

npm ERR! command C:\Windows\system32\cmd.exe /d /s /c node ./scripts/install.js || node-gyp rebuild
npm ERR! info install installing standalone, skipping download.
npm ERR! gyp ERR! find VS
npm ERR! gyp ERR! find VS msvs_version not set from command line or npm config
npm ERR! gyp ERR! find VS running in VS Command Prompt, installation path is:
npm ERR! gyp ERR! find VS "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC"
npm ERR! gyp ERR! find VS - will only use this version
@Nigtellios
Nigtellios / 1.md
Last active August 20, 2023 23:00
Notion Formulas

If field with percent value > 0, subtract % from field or show other field.

if(
	prop("PERCENT") > 0,
	subtract(
		toNumber(prop("VALUE A")),
		multiply(divide(prop("PERCENT"), 100), toNumber(prop("VALUE A")))
	),
	prop("VALUE B")