Skip to content

Instantly share code, notes, and snippets.

@yasirkula
yasirkula / TMP_IntegerText.cs
Last active May 12, 2024 22:04
Show numbers (int, float etc.) on TextMesh Pro texts without any GC allocations
//#define TMP_ROUND_DECIMALS // When defined, float and double values are rounded using Math.round
using TMPro;
public static class TMP_IntegerText
{
private static readonly char[] arr = new char[64]; // prefix + number + postfix can't exceed this capacity!
private static int charIndex = 0;
public static void SetText( this TMP_Text text, sbyte number )
# Read more about setting it up
# https://medium.com/@ljmocic/deploying-react-application-to-aws-s3-using-github-actions-85addacaeace
on:
push:
tags:
- '*'
jobs:
build:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Custom Scrollbar</title>
<style>
.scroll-box {
position: relative;
width: 300px; /* Adjust to fit your design */
@marcosdotme
marcosdotme / generate_parametrize.py
Created May 12, 2024 22:01
Generate inputs and expected outputs for `pytest.mark.parametrize`
import itertools
import json
from typing import Dict
from typing import List
FIELDS = {
'jira_project_key': True,
'issue_epic_number': False,
'issue_number': True,
@virattt
virattt / langgraph-financial-agent.ipynb
Created January 8, 2024 22:01
LangGraph-financial-agent.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Custom Scrollbar</title>
<style>
.scroll-box {
position: relative;
width: 300px; /* Adjust to fit your design */
@MichaelGatesDev
MichaelGatesDev / remove_dupes.py
Created August 10, 2021 01:55
Remap & Remove Duplicate Materials + Textures in Blender
import bpy
# credit to https://blender.stackexchange.com/questions/75790/how-to-merge-around-300-duplicate-materials/229803#229803
# remove duplicate materials
def remove_duped_materials():
mats = bpy.data.materials
for mat in mats:
(original, _, ext) = mat.name.rpartition(".")
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Custom Scrollbar</title>
<style>
.scroll-box {
position: relative;
width: 300px; /* Adjust to fit your design */
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Custom Scrollbar</title>
<style>
.scroll-box {
position: relative;
width: 300px; /* Adjust to fit your design */
@wilsonsilva
wilsonsilva / undo_last_commit.sh
Created June 21, 2017 15:47
Undo last commit but keep changes
# https://stackoverflow.com/a/44672195/3013522
git reset --soft HEAD~1