Skip to content

Instantly share code, notes, and snippets.

@arturkula
arturkula / shrink-wsl-disk-file.ps1
Created January 16, 2024 10:02
shrink wsl disk file
wsl --shutdown
wsl.exe --list --verbose
Optimize-VHD -Path .\ext4.vhdx -Mode full
@arturkula
arturkula / should have been pointers, but weren’t.ps1
Created November 30, 2022 08:47
should have been pointers, but weren’t
# Try the following command sequence:
git lfs uninstall
git reset --hard
git lfs install
git lfs pull
# In case if this is not working (because this was not working for me), the following hack may work:
git rm --cached -r .
@arturkula
arturkula / fix-git-lfs-should-have-been-a-pointer-but-was-not.ps1
Created September 28, 2022 13:20
fix-git-lfs-should-have-been-a-pointer-but-was-not.ps1
git rm --cached -r .
git reset --hard
git rm .gitattributes
git reset .
git checkout .
@arturkula
arturkula / vs nicknames.txt
Created January 12, 2022 08:38
Change Visual Studio versions nicknames
Set the nickname in the *.isolation.ini files in %ProgramFiles(x86)%\Microsoft Visual Studio\2017\[Version]\Common7\IDE.
Set the nickname in the state.json file in %ProgramData%\Microsoft\VisualStudio\Packages\_Instances\[InstanceId]\state.json
src: https://stackoverflow.com/questions/52386998/how-to-rename-visual-studio
NT SERVICE\MSSQLSERVER
@arturkula
arturkula / 3dObjectsRemove.txt
Created December 17, 2020 15:34
Remove 3D objects folder
regedit
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace
delete: {0DB7E03F-FC29-4DC6-9020-FF41B59E513A}
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace
@arturkula
arturkula / dark ssms.ps1
Created December 10, 2020 16:48
SQL SERVER Management Studio 18 – Enable Dark Theme
code-insiders "C:\Program Files (x86)\Microsoft SQL Server Management Studio 18\Common7\IDE\ssms.pkgundef"
// comment this line:
// Remove Dark theme
//[$RootKey$\Themes\{1ded0138-47ce-435e-84ef-9ec1f439b749}]
@arturkula
arturkula / install pwsh.ps1
Last active April 7, 2021 09:03
install/update powershell from powershell
iex "& { $(irm https://aka.ms/install-powershell.ps1) } -UseMSI"
using System;
using System.Diagnostics;
namespace Core.Helpers
{
public static class PerformanceHelper
{
public static TimeSpan MeasureExecution(Action action)
{
var stopwatch = new Stopwatch();
@arturkula
arturkula / setNodeOptionsEnvVar.ps1
Last active June 6, 2019 05:17
set NODE_OPTIONS env variable - increases memory for node
[Environment]::SetEnvironmentVariable("NODE_OPTIONS", "--max-old-space-size=8192", "User")