Skip to content

Instantly share code, notes, and snippets.

@Foadsf
Foadsf / latex-windows-vscode-setup.md
Created May 11, 2025 13:18
Complete step-by-step guide for setting up LaTeX on Windows with MiKTeX, VS Code, and automatic formatting using latexindent

Complete LaTeX Setup Guide for Windows with VS Code

This guide will help you set up a complete LaTeX environment on Windows with MiKTeX, VS Code, and automatic formatting with latexindent.

Prerequisites

  • Windows 10/11
  • Package manager (Chocolatey, Winget, or Scoop)
  • VS Code (or install it during this process)
@Foadsf
Foadsf / comparing-scilab-mingw-c-integration-methods.md
Created April 25, 2025 10:25
Comparison of techniques (Gateway/addinter vs. link/call) for integrating Scilab with MinGW-w64 GCC compiled C/C++ code on Windows.

Comparison of Scilab-MinGW C/C++ Integration Methods

This Gist compares five different approaches demonstrated in various GitHub repositories for integrating C/C++ code with Scilab on Windows using the MinGW-w64 GCC compiler toolchain. The goal is to understand the trade-offs and identify potentially clean, concise, and canonical methods.

Repositories Analyzed:

  1. Foadsf/scilab-c-cpp-mingw-example
  2. Foadsf/scilab-mingw-c-gateway-mwe
  3. Foadsf/minimal-scilab-c-gateway
  4. Foadsf/scilab-mingw-module (Note: URL points to my_foo6, seems related)
@Foadsf
Foadsf / scilab-c-mingw-integration-methods.md
Created April 25, 2025 09:41
A comprehensive comparison of four approaches for integrating C code with Scilab on Windows using MinGW-w64/MSYS2, highlighting trade-offs in complexity, flexibility, and implementation details.

Scilab-C Integration Methods Comparison (MinGW/MSYS2 on Windows)

This document compares four different approaches for integrating C code with Scilab on Windows using the MinGW-w64 GCC compiler from MSYS2. Each approach offers different trade-offs in terms of complexity, flexibility, and maintainability.

Overview of the Four Approaches

  1. minimal-scilab-c-gateway: A minimalistic example of a Scilab C gateway using the modern API.
  2. scilab-mingw-c-gateway-mwe: A Minimal Working Example (MWE) for C/C++ gateways with Scilab.
  3. scilab-mingw-c-call-minimal-example: Direct DLL calling using Scilab's link and call functions.
  4. scilab-mingw-module (my_foo6): A more complex gateway example demonstrating multiple input/output types.
@Foadsf
Foadsf / taskjuggler-lessons-learned.md
Created April 18, 2025 09:32
TaskJuggler 3.8.1 Lessons Learned: Tips, Tricks, and Workarounds A comprehensive guide to using TaskJuggler 3.8.1 with modern Ruby versions, addressing common syntax issues, bugs, and report generation challenges.

TaskJuggler 3.8.1 Lessons Learned

Introduction

TaskJuggler is a powerful project management tool that uses a text-based syntax to define project plans, resources, and tasks. While the software is mature and feature-rich, its latest version (3.8.1 as of 2024) has some quirks and compatibility issues, especially with newer Ruby versions. This document shares practical lessons learned while working with TaskJuggler 3.8.1.

Basic Project Structure

TaskJuggler 3 has a specific file structure and syntax that differs significantly from version 2. Here's the basic structure of a TaskJuggler 3 project file:

using System;
public class HelloWorld
{
public static void Main(string[] args)
{
Console.WriteLine("Hello, MSBuild!");
}
}

Force Delete Files/Folders on Windows with IObit Unlocker and a CMD Batch Script

This Gist shares how to install IObit Unlocker using Chocolatey and use a CMD batch script to force delete stubborn files or folders on Windows, including a verification step. This was tested on a minimal Windows 10 setup (Tiny10) on April 14, 2025.

Step 1: Install IObit Unlocker via Chocolatey

  1. Ensure Chocolatey is installed:
    choco --version
@Foadsf
Foadsf / Install-Winget.ps1
Created April 10, 2025 12:44
Complete script to install Windows Package Manager (winget) on Tiny10/LTSC without Microsoft Store
# Complete Winget Installer for Tiny10/LTSC
# Run as Administrator
# Created on: April 10, 2025
# Ensure we're running with admin rights
if (-not ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]"Administrator")) {
Write-Host "This script requires administrative privileges. Please run as Administrator." -ForegroundColor Red
exit 1
}
@Foadsf
Foadsf / HyperV_External_Virtual_Switch.md
Created April 9, 2025 06:18
Fixed Hyper‑V VM connectivity by creating an external virtual switch.

Resolving Internet Connectivity in a Hyper‑V Virtual Machine

Short Description:
Fixed Hyper‑V VM connectivity by creating an external virtual switch.


Overview

I was experiencing a loss of Internet connectivity in a Windows virtual machine running on Hyper‑V. Although the VM received an IP address via the Default Switch, it could not reach the Internet—the gateway (172.29.128.1), external IP addresses (e.g., 8.8.8.8), or HTTPS endpoints were unreachable.

Building Goose for Windows

This guide will help you build and run the Goose AI chat UI on Windows.

Prerequisites

You'll need the following tools installed on your Windows machine:

  1. Rust - Install via one of these methods:
@Foadsf
Foadsf / README.md
Last active February 20, 2025 14:26
Automated script to install Python's hunspell package on Windows by setting up vcpkg and required directory structure.

Hunspell Installer for Python on Windows

This script automatically installs the Python hunspell package on Windows by setting up the necessary environment.

What this script does

  1. Checks for and installs vcpkg if not present
  2. Installs hunspell C++ library using vcpkg
  3. Creates a virtual drive and directory structure expected by the hunspell Python package
  4. Copies required header and library files to the expected locations