Skip to content

Instantly share code, notes, and snippets.

@startergo
startergo / allow_write.md
Created December 25, 2024 18:01
Allow write access to removable drives not protected by BitLocker

(Deny write access to removable drives not protected by BitLocker) HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Policies\Microsoft\FVE

RDVDenyWriteAccess DWORD

(delete) = Allow (default)

1 = Deny

0 = Allow

@startergo
startergo / robocopy.md
Last active December 25, 2024 19:42
How to copy file/folder and preserve their creation date in Windows
robocopy "C:\your source folder" "F:\your destination folder" /e /dcopy:DAT /MT /z

Enable Vmware shared folders in PowerShell context:

net use Z: "\\vmware-host\Shared Folders"

Copy options

@startergo
startergo / clone_push_repo.md
Last active December 18, 2024 03:49
Clone remote repo and push to your repo
git show-ref
git remote add <remote_Branch> <remote_repo> 
git fetch
git add .
git commit -m 'reinitialized files'
git push -f --no-thin https:<your repo> HEAD:refs/heads/<remote branch>
@startergo
startergo / msys2_git.md
Last active January 8, 2025 01:16
Git credentials manager add support for a MSYS2 Shell

https://github.com/git-for-windows/git/wiki/Install-inside-MSYS2-proper

  • Open a PowerShell as administrator, and enter the following command:
New-Item -ItemType SymbolicLink -Path 'C:\msys64\opt\git-for-windows-mingw64-bin' -Target 'C:\Program Files\Git\mingw64\bin'

This asumes that both paths exist and you have both Git for Windows and MSYS2 installed on those default locations, change them according to your needs.

  • Next, add the following 2 lines to your .gitconfig file in you MSYS2 homefolder:
[credential]
  • How to add your terminal to Developer Tools:
  • Run sudo spctl developer-mode enable-terminal in your terminal.
  • Go to System Preferences, and then to Security & Privacy.
  • Under the Privacy tab, an item called Developer Tools should be present. Navigate to it.
  • Ensure that your terminal is listed and enabled. If you're using a third-party terminal like iTerm, be sure to add it to the list. (You may have to click the lock in the bottom-left corner and authenticate.)
  • Restart your terminal.
@startergo
startergo / vmware_admin.md
Created December 3, 2024 11:20
Error: You must have administrative privileges to modify or repair this installation (VMware)
  • Find the Installer in C:\Windows\Installer\ by opening Windows explorer search and enable search in file contents: image

  • Run this command in elevated command prompt:

msiexec.exe /i "C:\Windows\Installer\171d2a.msi"
@startergo
startergo / CPUID.cs
Last active December 2, 2024 08:53
CPUID,cs C# code for generation of an executable
using System;
namespace CPUID
{
using System;
using System.Globalization;
using System.Linq;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Text;
@startergo
startergo / ntfs-3g_macOS.md
Last active December 1, 2024 15:09
Installing NTFS-3g on macOS
brew tap gromgit/homebrew-fuse
brew install ntfs-3g-mac
  • Or with MacPorts:
sudo port install NTFS-3g
@startergo
startergo / qemu-img.md
Last active June 19, 2025 16:54
How to: Use qemu-img command to convert between vmdk, raw, qcow2, vdi, vhd, vhdx formats/disk images (qemu-img create, snapshot, resize etc.)
  • First we need to have qemu installed on the system, for most of Linux systems, we can install “qemu-utils” for Windows we can download QEMU disk image utility from here

  • Other related questions

How to open raw disk from VMware
How to open qcow2 disk from VMware
How to open vdi disk from VMware
How to open raw disk from Hyper-V
How to open qcow2 disk from Hyper-V
How to open vdi disk from Hyper-V