: Idle (default)
powershell -command " Write-Host -NoNewline ([char]27 + \"]9;4;3\" + [char]7) "
: WIP (rotation)
powershell -command " Write-Host -NoNewline ([char]27 + \"]9;4;0\" + [char]7) "
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Should I use URLDownloadToFile? | |
// Answered by Mike Caron : https://stackoverflow.com/a/5185008 | |
#define _CRT_SECURE_NO_WARNINGS | |
#define WIN32_LEAN_AND_MEAN | |
#include <windows.h> | |
#include <Urlmon.h> | |
#include <string> | |
#include <functional> | |
#pragma comment(lib, "User32.lib") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@rem Download and build script for NetHack for Windows x64 Desktop, VC++2022 | |
@echo off | |
setlocal EnableDelayedExpansion | |
set /a errorno=1 | |
for /F "delims=#" %%E in ('"prompt #$E# & for %%E in (1) do rem"') do set "esc=%%E" | |
set "ROOT=%CD%" | |
: | |
: Check prerequisites | |
: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
setlocal EnableDelayedExpansion | |
set /a errorno=1 | |
for /F "delims=#" %%E in ('"prompt #$E# & for %%E in (1) do rem"') do set "_ESC=%%E" | |
cd /d "%~dp0" | |
set /a _E =0 | |
set /a _E+=1 && if not exist "Alpine.zip" ( curl -JOL https://github.com/yuk7/AlpineWSL/releases/download/3.18.4-0/Alpine.zip ) | |
set /a _E+=1 && if not exist "Alpine.zip" goto :ERROR | |
set /a _E+=1 && if not exist "Alpine.exe" ( tar -xkf .\Alpine.zip ) |
Problem: winget
CLI command keep reporting a mysterious error code 0x8a15005e
Solution: Update winget.exe
via aka.ms/getwinget
pwsh.exe
cd $env:USERPROFILE\Desktop
curl.exe -JOL https://aka.ms/getwinget
Add-AppxPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.txt.msixbundle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
using System.Runtime.InteropServices; | |
using UnityEditor; | |
using UnityEngine; | |
internal static class Test { | |
[MenuItem("Help/Test/SHOpenFolderAndSelectItems")] | |
private static void MenuItem_MyMenu_SHOpenFolderAndSelectItems() { | |
string path = "C:/Windows/system.ini"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// This Unity Editor script reports all TextureImporter settings as CSV file. | |
// | |
// Usage: | |
// - Invoke "UnityEditor > Help > TextureImporterReporter > Report all TextureImporter settings as CSV" | |
// - Script creates report CSV file and reports its file name. | |
// | |
// License | |
// ------- | |
// SPDX-FileCopyrightText: Copyright (c) Takayuki Matsuoka |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Simple in-memory .ini file parser in C++20 | |
// | |
// - Header only library | |
// - No exception, heap allocation and callback | |
// - Depends only <stddef.h> | |
// - Opt-in compatibility with <string_view> (SIMPLE_INI_FILE_HPP_VIEW_TYPE) | |
// | |
// Usage | |
// ----- | |
// |
cmd.exe
: https://github.com/cnlohr/mini-rv32ima/tree/7185ec78442060e032bb33a71e6fe2f4319409e8
set "MINI_RV32IMA_HASH=7185ec78442060e032bb33a71e6fe2f4319409e8"
cd /d "%USERPROFILE%\Documents"
if not exist my-mini-rv32ima ( mkdir my-mini-rv32ima )
cd my-mini-rv32ima
NewerOlder