In git, there are no renames. It uses "heuristics" to detect files been deleted-and-added that are "actually" renamed. The "good practice" is to never mix these "renames" with file modifications, else git will loose the track of "renames" and thus history navigation for these files will become a serious pain. But sometimes you "forget" about these "great" practices. The script to fix an accidental loss of real rename below is to the resque.
Wednesday, 17 July 2024
Monday, 25 September 2023
WIN32_LEAN_AND_MEAN and DuckDB
This keeps striking me every other year when building something from sources.
Got a ton of windows.h-related errors when compiling C++ sources is a typical sign.
The correct way would be to define WIN32_LEAN_AND_MEAN when building:
git clone git@github.com:duckdb/duckdb.git --branch v0.8.1 --single-branch
cd duckdb
python scripts/amalgamation.py
md build
cd build
cmake -G "Visual Studio 17 2022" -A x64 -DCMAKE_BUILD_TYPE=Debug -DAMALGAMATION_BUILD=ON -D CMAKE_CXX_FLAGS="/D WIN32_LEAN_AND_MEAN" ..
cmake --build . --config Debug
Wednesday, 6 September 2023
Make font thicker in Chrome, Electron, VS Code, Obsidian etc.
* {text-shadow: transparent 0px 0px 0px, rgba(0,0,0,1) 0px 0px 0px;}
Friday, 1 September 2023
Friday, 9 June 2023
Color coding for Visual Studio
https://marketplace.visualstudio.com/items?itemName=ryzngard.Carnation2022020
https://studiostyl.es/schemes/notepad2-c
https://studiostyl.es/schemes/search?q=notepad
https://studiostyl.es/schemes/github-light-for-notepad
Monday, 22 May 2023
Turn off "Modern standby" in Windows
Follow this: https://www.elevenforum.com/t/how-to-enable-missing-power-plan-profiles-on-windows-10-20h2-and-later-and-windows-11.562/
Setting PlatformAoAcOverride to 0 under HKLM\System\CurrentControlSet\Control\Power. Removing the entry again to get back modern standby.
Saturday, 20 May 2023
Windows startup locations
Shell:startup
Shell:common startup
%ProgramData%\Microsoft\Windows\Start Menu\Programs\StartUp
%appdata%\Microsoft\Windows\Start Menu\Programs\Startup