Skip to content

Instantly share code, notes, and snippets.

@ChampionAsh5357
ChampionAsh5357 / 1192-1193-primer.md
Last active February 13, 2024 05:19
Minecraft 1.19.2 -> 1.19.3 Mod Migration Primer

Minecraft 1.19.2 -> 1.19.3 Mod Migration Primer

This is a high level, non-exhaustive overview on how to migrate your mod from 1.19.2 to 1.19.3 using Forge.

This primer is licensed under the Creative Commons Attribution 4.0 International, so feel free to use it as a reference and leave a link so that other readers can consume the primer.

If there's any incorrect or missing information, please leave a comment below. Thanks!

Feature Flags

@svemat01
svemat01 / autoComplete.md
Last active January 16, 2022 00:33
Discord.JS AutoComplete Quick docs help

AutoComplete DJS v13.3.0

What is autoComplete?

"Autocomplete is basically choices but dynamic. every time the user presses a key in an autocomplete option, the bot gets an event and it can respond with what strings it wants discord to display as choices instead of having the choices be static." - Urcute#3119 on Discord

How do we use it?

For this guide, our command will be named autocomplete, this is not some built in command.

Prepare option for autocomplete

Before we can start to recieve autocomplete events on an option, we have to actually tell discord that we want it.

@sindresorhus
sindresorhus / esm-package.md
Last active May 6, 2024 13:26
Pure ESM package

Pure ESM package

The package that linked you here is now pure ESM. It cannot be require()'d from CommonJS.

This means you have the following choices:

  1. Use ESM yourself. (preferred)
    Use import foo from 'foo' instead of const foo = require('foo') to import the package. You also need to put "type": "module" in your package.json and more. Follow the below guide.
  2. If the package is used in an async context, you could use await import(…) from CommonJS instead of require(…).
  3. Stay on the existing version of the package until you can move to ESM.
@ewen-lbh
ewen-lbh / remove_deployments_tab.py
Last active September 14, 2023 01:48
Remove the "Deployments" tab from github.com
"""
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
@mikhailov-work
mikhailov-work / turbo_colormap.glsl
Last active February 19, 2024 22:18
Turbo Colormap Polynomial Approximation in GLSL
// Copyright 2019 Google LLC.
// SPDX-License-Identifier: Apache-2.0
// Polynomial approximation in GLSL for the Turbo colormap
// Original LUT: https://gist.github.com/mikhailov-work/ee72ba4191942acecc03fe6da94fc73f
// Authors:
// Colormap Design: Anton Mikhailov (mikhailov@google.com)
// GLSL Approximation: Ruofei Du (ruofei@google.com)
@Matthias247
Matthias247 / async_await_cancellation.md
Created May 28, 2019 06:09
Async/Await - The challenges besides syntax - Cancellation

Async/Await - The challenges besides syntax - Cancellation

This is the second article in a series of articles around Rusts new async/await feature. The first article about interfaces can be found here.

In this part of the series we want to a look at a mechanism which behaves very different in Rust than in all other languages which feature async/await support. This mechanism is Cancellation.

@williewillus
williewillus / 1132_to_114.xml
Last active July 16, 2022 02:14
1.13.2 -> 1.14 migration mappings
<?xml version="1.0" encoding="UTF-8"?>
<migrationMap>
<name value="1.13.2 to 1.14" />
<description value="1.13.2 to 1.14 MCP changes" />
<entry oldName="net.minecraft.GameVersion" newName="net.minecraft.util.MinecraftVersion" type="class" />
<entry oldName="net.minecraft.advancements.AdvancementList.Listener" newName="net.minecraft.advancements.AdvancementList.IListener" type="class" />
<entry oldName="net.minecraft.advancements.RequirementsStrategy" newName="net.minecraft.advancements.IRequirementsStrategy" type="class" />
<entry oldName="net.minecraft.advancements.criterion.AbstractCriterionInstance" newName="net.minecraft.advancements.criterion.CriterionInstance" type="class" />
<entry oldName="net.minecraft.block.Block.EnumOffsetType" newName="net.minecraft.block.Block.OffsetType" type="class" />
<entry oldName="net.minecraft.block.BlockAbstractBanner" newName="net.minecraft.block.AbstractBannerBlock" type="class" />
@Lazersmoke
Lazersmoke / CodeItYourself.md
Last active January 10, 2019 19:45
Code it Yourself

Code it Yourself

This guide will teach you how to get started developing civ server plugins. In order for you to follow this guide, you must already know how to code in Java. If you don't know Java, you should learn it before attempting to develop plugins in Java.

Dev Setup

You will need Java, the Java build tool Maven, the version control tool Git, and a text editor you know how to use. You should install these things using your package manager (sudo apt-get install for Ubuntu) or download and install them in Windows.

Building Spigot

@Lazersmoke
Lazersmoke / Building.md
Last active December 15, 2018 02:41
Instructions for using the Travis CI/Jitpack build system

Travis CI/Jitpack Build System

Unless otherwise specified, these files all go in the root of your Github repository.

Travis

We use Travis CI to build and test on each commit or pull request to the Github repository. The Travis setup is all the defaults, plus this as .travis.yml:

# Travis build script for mineman
@linar-jether
linar-jether / simple_python_datasource.py
Last active May 24, 2023 01:22
Grafana python datasource - using pandas for timeseries and table data. inspired by and compatible with the simple json datasource ---- Up-to-date version maintained @ https://github.com/panodata/grafana-pandas-datasource
from flask import Flask, request, jsonify, json, abort
from flask_cors import CORS, cross_origin
import pandas as pd
app = Flask(__name__)
cors = CORS(app)
app.config['CORS_HEADERS'] = 'Content-Type'