Skip to content

Instantly share code, notes, and snippets.

View hugows's full-sized avatar
🏠
Working from home

Hugo Schmitt hugows

🏠
Working from home
  • Brazil
  • 09:13 (UTC -03:00)
View GitHub Profile
@ngxson
ngxson / FAQ.md
Last active February 27, 2025 00:51
convert ARM NEON to WASM SIMD prompt

Why did you do this?

Relax, I only have one Sunday to work on idea, literally my weekend project. So I tried Deepseek to see if it can help. Surprisingly, it works and it saves me another weekend...

What is your setup?

Just chat.deepseek.com (cost = free) with prompts adapted from this gist.

Does it work in one-shot or I have to prompt it multiple times?

@stefantalpalaru
stefantalpalaru / keto.md
Last active February 27, 2025 00:34
keto.md

brain

  • "In humans, both acute and chronic increases in ketone body availability to the central nervous system cause massive changes in cerebral fuel metabolism. In healthy middle-aged subjects, an i.v. infusion of BHB caused approximately 14% decrease in cerebral glucose consumption while oxygen use was unchanged, suggesting that ketone bodies, even when supplied acutely, enter the brain and may be utilized immediately as an alternative fuel to glucose. Similar cerebral metabolic changes have also been demonstrated in young individuals, however, at lower infusion rates, and thus lower BHB concentrations, glucose uptake does not seem to be affected. Together, this suggests an acute cerebral glucose-sparing effect when ketone availability is high." - "Effects of Ketone Bodies on Brain Metabolism and Function in Neurodegenerative Diseases" (2020)

  • "Recent evidence suggests that myelin lipids may act as glial energy reserves when glucose is lacking,

@sibelius
sibelius / woovi_challenge.md
Last active December 24, 2024 16:25
Woovi Challenge
@IcedMango
IcedMango / karabiner_double_tap_toggle_raycast.json
Last active November 10, 2023 11:26
Enable double tap cmd/option toggle for Raycast using karabiner
{
"title": "Raycast Karabiner Config",
"rules": [
{
"description": "Double click cmd Toggle Raycast(Hotkey: ctrl+option+cmd+Esc)",
"manipulators": [
{
"conditions": [
{
"name": "command_pressed",
@knu
knu / barrier_karabiner.lua
Last active April 26, 2024 17:58
Barrier and Karabiner-Elements integration using Hammerspoon
knu = require("knu") -- https://github.com/knu/hs-knu
-- Switch between Karabiner-Elements profiles as Barrier enters a different host
do
-- Configure Barrier (https://github.com/debauchee/barrier) to output log to ~/Library/Logs/barrier.log
local logFile = os.getenv("HOME") .. "/Library/Logs/barrier.log"
local lineNo = 1
local host = nil
local defaultProfile = "Default"
local profileForHost = function (host)
@jarek-przygodzki
jarek-przygodzki / rob-pike-comments.md
Last active August 5, 2024 17:04
Rob Pike on commnts

Comments

A delicate matter, requiring taste and judgement. I tend to err on the side of eliminating comments, for several reasons. First, if the code is clear, and uses good type names and variable names, it should explain itself. Second, comments aren't checked by the compiler, so there is no guarantee they're right, especially after the code is modified. A misleading comment can be very confusing. Third, the issue of typography: comments clutter code.

Rob Pike, "Notes on Programming in C"

@d7samurai
d7samurai / .readme.md
Last active February 21, 2025 06:10
Minimal D3D11

Minimal D3D11

Minimal D3D11 reference implementation: An uncluttered Direct3D 11 setup + basic rendering primer and API familiarizer. Complete, runnable Windows application contained in a single function and laid out in a linear, step-by-step fashion that should be easy to follow from the code alone. ~200 LOC. No modern C++, OOP or (other) obscuring cruft. View on YouTube

hollowcube

Also check out Minimal D3D11 part 2, reconfigured for instanced rendering and with a smaller, tighter, simplified overall code structure, or Minimal D3D11 part 3, with shadowmapping + showcasing a range of alternative setup and rendering techniques.

@gaearon
gaearon / MyResponsiveComponent.js
Created November 1, 2018 10:05
Examples from "Making Sense of React Hooks"
function MyResponsiveComponent() {
const width = useWindowWidth(); // Our custom Hook
return (
<p>Window width is {width}</p>
);
}
@magbicaleman
magbicaleman / index.js
Last active May 6, 2020 19:21
Crude Dynamic Import Example on Create React App index.js scaffold
import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import registerServiceWorker from './registerServiceWorker';
class Dynamic extends Component {
constructor(props) {
super(props);
this.state = { module: null };
}
@lattner
lattner / TaskConcurrencyManifesto.md
Last active February 28, 2025 08:22
Swift Concurrency Manifesto