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
  • 17:24 (UTC -12:00)
View GitHub Profile
@stefantalpalaru
stefantalpalaru / keto.md
Last active August 18, 2024 12:26
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 May 2, 2024 03:03
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 September 10, 2024 08:32
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 pt2, reconfigured for instanced rendering and with a smaller, tighter, simplified overall code structure, or Minimal D3D11 pt3, 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 September 14, 2024 20:24
Swift Concurrency Manifesto

For a while, I thought that our modern culture's relationship to science best resembled the Catholic Church during the middle ages. Priests delivering sermons in Latin, indulgences, poor families of believers praying one of their sons would be bright enough for the clergy... Then I discovered the Druze.

"But when I asked him about the Druze faith, he gave me an unexpected reply. 'I know nothing about the Druze', the pre-eminent leader of the Druze declared with a violent wave of his arm. From his piles of books he selected a couple by Tariq Ali and gave them to me as gifts. He invited me to visit him at his palace in the mountains. And then he said goodbye. Either the most powerful Druze man in Lebanon, an intellectual in his own right, had been excluded from the teachings of his own religion, or else he knew better than to pass them on to an outsider. I had every intention of taking up his invitation to spend time among the Druze communities, but first I would have to find someone more willing to talk