Skip to content

Instantly share code, notes, and snippets.

@kconner
kconner / macOS Internals.md
Last active May 10, 2024 17:04
macOS Internals

macOS Internals

Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.

Starting Points

How to use this gist

You've got two main options:

function setInputValueAndClickButton(value) {
const inputElement = document.getElementById('order-market-input');
if (inputElement) {
inputElement.value = value;
const inputEvent = new Event('input', {
bubbles: true,
cancelable: true,
});
@JeffM2501
JeffM2501 / imgui_docking_exmaple.cpp
Created April 21, 2021 15:14
Example of how to do editor style docking in ImGui for raylib
/*******************************************************************************************
*
* raylib [core] example - Third Person Orbit Camera Example
*
* Welcome to raylib!
*
* To test examples, just press F6 and execute raylib_compile_execute script
* Note that compiled executable is placed in the same folder as .c file
*
* You can find all basic examples on C:\raylib\raylib\examples folder or
@hurricane-voronin
hurricane-voronin / README.md
Last active May 10, 2024 16:59
Naming Classes Without a 'Manager'
@paduvi
paduvi / FlatCnnLayer.py
Last active May 10, 2024 16:59
Hierarchical Softmax CNN Classification
import torch
import torch.nn as nn
import torch.nn.init as init
dropout_prob = 0.5
class FlatCnnLayer(nn.Module):
def __init__(self, embedding_size, sequence_length, filter_sizes=[3, 4, 5], out_channels=128):
super(FlatCnnLayer, self).__init__()
@mjbalcueva
mjbalcueva / calendar.tsx
Last active May 10, 2024 16:58
shadcn ui calendar custom year and month dropdown
"use client"
import * as React from "react"
import { buttonVariants } from "@/components/ui/button"
import { ScrollArea } from "@/components/ui/scroll-area"
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@/components/ui/select"
import { cn } from "@/lib/utils"
import { ChevronLeft, ChevronRight } from "lucide-react"
import { DayPicker, DropdownProps } from "react-day-picker"
@mjbalcueva
mjbalcueva / password-input.tsx
Last active May 10, 2024 16:58
shadcn ui custom password input
"use client"
import { forwardRef, useState } from "react"
import { EyeIcon, EyeOffIcon } from "lucide-react"
import { Button } from "@/components/ui/button"
import { Input, InputProps } from "@/components/ui/input"
import { cn } from "@/lib/utils"
const PasswordInput = forwardRef<HTMLInputElement, InputProps>(
({ className, ...props }, ref) => {
@txhammer68
txhammer68 / linux.md
Last active May 10, 2024 16:57
Linux Tips

Linux Tips (Debian Based distros)

Some usefull tips i have collected over the years, use at own risk.

  • Users & Groups

    • Add user to group
      sudo usermod -a -G cdrom userName
      sudo usermod -aG vboxsf $USER
  • Change root password
    sudo passwd root

@Zeinok
Zeinok / wine-breeze-dark-theme.md
Last active May 10, 2024 16:57
Breeze Dark theme for Wine

Made possible with this reddit post.

Install

wine regedit wine-breeze-dark.reg

Uninstall (Reset Wine color scheme)

wine regedit wine-reset-theme.reg