Skip to content

Instantly share code, notes, and snippets.

@rngtm
rngtm / HexagonTile.hlsl
Last active May 10, 2024 04:56
Unity ShaderGraphのCustomFunctionで六角形タイルを作るためのHLSLファイル
void HexagonTile_float(
float2 UV,
float Scale,
out float Hexagon, // 六角形
out float2 HexPos, // 六角形の位置
out float2 HexUV, // 六角形内のUVを出力
out float2 HexIndex // 六角形の番号
)
{
///////////////////////////////////////////////////////////////////
@reinvanoyen
reinvanoyen / terminal-prompt-git-branch-zsh.md
Last active May 10, 2024 04:54
Add Git Branch Name to Terminal Prompt (MacOS zsh)

Add Git Branch Name to Terminal Prompt (zsh)

Updated for MacOS with zsh

  • Catalina
  • Big Sur
  • Monterey
  • Ventura
  • Sonoma

screenshot

@Dziurwa14
Dziurwa14 / codes.md
Last active May 10, 2024 04:52
Discord error codes

Error Codes

All collected Discord error codes, categorized by type (first 2 digits).

Miscellaneous

Code Message
0 General error (such as a malformed request body, amongst other things)

Unknown API object

@azagniotov
azagniotov / beautiful.rest.api.docs.in.markdown.md
Last active May 10, 2024 04:52
Example to create beautiful REST API docs in Markdown, inspired by Swagger API docs.
@troyhunt
troyhunt / Eye4Fraud-SiteName-Values.csv
Last active May 10, 2024 04:51
Eye4Fraud SiteName values
Lovelyskin 3338541
Jomashop Magento 2342771
iTechDeals 1411036
tilebar.com 910699
AppliancesConnection 663130
CANADIANAPPLIANCE.CA 645213
MoodFabrics 585985
Botach.com 488274
BeachCamera 483356
ezcontactsusa 464685
@policante
policante / BaseNavigationController.swift
Created February 20, 2019 20:40
UINavigationController swipe back like Facebook, Instagram
class BaseNavigationController: UINavigationController, UINavigationControllerDelegate {
var interactivePopTransition: UIPercentDrivenInteractiveTransition!
override func viewDidLoad() {
self.delegate = self
}
func navigationController(_ navigationController: UINavigationController, willShow viewController: UIViewController, animated: Bool) {
addPanGesture(viewController)
@saiyam1814
saiyam1814 / k8s1.30.sh
Created April 22, 2024 13:56
k8s1.30.sh
echo "step1- install kubectl,kubeadm and kubelet 1.29.0"
sudo mkdir -m 755 /etc/apt/keyrings
sudo apt-get install -y apt-transport-https ca-certificates curl gpg
curl -fsSL https://pkgs.k8s.io/core:/stable:/v1.30/deb/Release.key | sudo gpg --dearmor -o /etc/apt/keyrings/kubernetes-apt-keyring.gpg
echo 'deb [signed-by=/etc/apt/keyrings/kubernetes-apt-keyring.gpg] https://pkgs.k8s.io/core:/stable:/v1.30/deb/ /' | sudo tee /etc/apt/sources.list.d/kubernetes.list
sudo apt update -y
sudo apt -y install vim git curl wget kubelet kubeadm kubectl
@StepTurtle
StepTurtle / lio_sam_with_object_removal.md
Last active May 10, 2024 04:52
Create LIO-SAM map with object removal
@egtann
egtann / example.templ
Last active May 10, 2024 04:44
Using a strict CSP with HTMX and Templ
// Example component with styling and script tags. The script+style will work even when
// retrieved after page load via HTMX because of our X-Nonce header/middleware.
templ MyComponent() {
<style nonce={ nonceFrom(ctx) }>
.red {
color: red;
}
</style>
<script nonce={ nonceFrom(ctx) }>
/*
Do not modify this version of the file. It will be copied over when any of the project's targets are built.
If you wish to modify mraid.js, modify the version located at mopub-sdk-common/mraid/mraid.js.
*/
(function() {
var isIOS = (/iphone|ipad|ipod/i).test(window.navigator.userAgent.toLowerCase());
if (isIOS) {
console = {};
console.log = function(log) {
var iframe = document.createElement('iframe');