Skip to content

Instantly share code, notes, and snippets.

View HashWarlock's full-sized avatar
👾
bits bending

Joshua W HashWarlock

👾
bits bending
View GitHub Profile
@jtgi
jtgi / util.ts
Last active January 29, 2024 20:32
Frame Response Helper - Use web standard response
// next.js usage
export default function handler() {
return frameResponse({
image: `https://domain.com/image.gif`,
buttons: [
{ text: 'Action 1' },
{ text: 'Action 2' },
]
});
@Maar-io
Maar-io / benchmarking-rmrk.md
Last active December 29, 2022 20:03
Substrate pallet benchmarking (RMRK example)

Use this documentation on benchmarking. It is very good and will give all info you need.

To start existing benchmark tests I propose following steps:

  • rename pallets/rmrk-core/src/weights.rs to old_weights.rs. Just to keep it for referrence
  • examine the tests in benchmarks.rs files. They will produce measurements for the new weights.rs file
  • compile node with --features runtime-benchmarks
  • since rmrk node is missing production profile, use --profile=release in cargo build. Therefore instead of:
cd bin/node/cli
@jmatsushita
jmatsushita / README
Last active November 8, 2024 16:52
Setup nix, nix-darwin and home-manager from scratch on an M1 Macbook Pro
###
### [2023-06-19] UPDATE: Just tried to use my instructions again on a fresh install and it failed in a number of places.
###. Not sure if I'll update this gist (though I realise it seems to still have some traffic), but here's a list of
###. things to watch out for:
### - Check out the `nix-darwin` instructions, as they have changed.
### - There's a home manager gotcha https://github.com/nix-community/home-manager/issues/4026
###
# I found some good resources but they seem to do a bit too much (maybe from a time when there were more bugs).
# So here's a minimal Gist which worked for me as an install on a new M1 Pro.
@tobiasvl
tobiasvl / install_aseprite.sh
Last active May 5, 2024 21:44
The commands to build aseprite on Fedora
# Copied from https://github.com/aseprite/aseprite/blob/master/INSTALL.md#skia-on-linux
sudo yum install -y gcc-c++ cmake ninja-build libX11-devel libXcursor-devel mesa-libGL-devel fontconfig-devel
mkdir $HOME/deps
cd $HOME/deps
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
git clone -b aseprite-m71 https://github.com/aseprite/skia.git
export PATH="${PWD}/depot_tools:${PATH}"
cd skia
@chevdor
chevdor / 0_readme.adoc
Last active March 1, 2022 07:06
Docker compose for a polkadot local chain

Substrate/Polkadot local chain

This gists contains a collection of docker-compose config for Polkadot and Substrate. You can find it here.

You may clone this gist with:

git clone [email protected]:be461d11c56baecb0e7bbcb920e964fb.git
@jagrosh
jagrosh / Github Webhook Tutorial.md
Last active November 18, 2024 08:23
Simple Github -> Discord webhook

Step 1 - Make a Discord Webhook

  1. Find the Discord channel in which you would like to send commits and other updates

  2. In the settings for that channel, find the Webhooks option and create a new webhook. Note: Do NOT give this URL out to the public. Anyone or service can post messages to this channel, without even needing to be in the server. Keep it safe! WebhookDiscord

Step 2 - Set up the webhook on Github

  1. Navigate to your repository on Github, and open the Settings Settings
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active November 17, 2024 01:28
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname