Skip to content

Instantly share code, notes, and snippets.

View iErik's full-sized avatar
🌀
Tapping keys

Erik Isidore iErik

🌀
Tapping keys
View GitHub Profile
@SorenSaket
SorenSaket / main.odin
Last active May 9, 2024 13:36
GLFW, OpenGL Window Tutorial in Odin language
// GLFW and OpenGL example with very verbose comments and links to documentation for learning
// By Soren Saket
// semi-colons ; are not requied in odin
//
// Every Odin script belongs to a package
// Define the package with the package [packageName] statement
// The main package name is reserved for the program entry point package
// You cannot have two different packages in the same directory
@MeguminSama
MeguminSama / Discord Experiments.js
Last active May 7, 2024 04:46
Discord Experiments.js
let cache; webpackChunkdiscord_app.push([["wp_isdev_patch"], {}, r => cache=r.c]);
var UserStore = Object.values(cache).find(m => m?.exports?.default?.getUser).exports.default;
var actions = Object.values(UserStore._dispatcher._actionHandlers._dependencyGraph.nodes);
var user = UserStore.getCurrentUser();
actions.find(n => n.name === "ExperimentStore").actionHandler.CONNECTION_OPEN({
type: "CONNECTION_OPEN", user: {flags: user.flags |= 1}, experiments: [],
});
actions.find(n => n.name === "DeveloperExperimentStore").actionHandler.CONNECTION_OPEN();
webpackChunkdiscord_app.pop(); user.flags &= ~1; "done";
Vue.config.optionMergeStrategies.render = (parentVal, childVal) => {
if (parentVal) {
const mergedParentVal = function render (...args) {
args.push([ childVal.apply(this, args) ])
return parentVal.apply(this, args)
}
return mergedParentVal
}
@jornane
jornane / GROW.md
Created October 23, 2017 12:12
How to grow a partition in Linux

How to grow a partition in Linux

This guide will walk you through the steps required to grow a partition in Linux. You will have to reboot through this guide.

  1. If possible, make a snapshot.

Often, you will want to grow the partition table because you made your virtual hard disk too small, and you tried to extend it in your hypervisor, only to find out that your partition is still the same size as it was before.

@IgorDePaula
IgorDePaula / cpf.js
Last active November 3, 2021 13:40
vee-validate em pt-br
function calcChecker1 (firstNineDigits) {
let sum = null
for (let j = 0; j < 9; ++j) {
sum += firstNineDigits.toString().charAt(j) * (10 - j)
}
const lastSumChecker1 = sum % 11
const checker1 = (lastSumChecker1 < 2) ? 0 : 11 - lastSumChecker1
@lopspower
lopspower / README.md
Last active May 10, 2024 17:08
Hexadecimal color code for transparency

Hexadecimal color code for transparency

Twitter

How to set transparency with hex value ?

For example, you want to set 40% alpha transparence to #000000 (black color), you need to add 66 like this #66000000.

Download This sample on Google Play Store

@j1cs
j1cs / improve_fonts.md
Last active January 23, 2024 15:59
Improve fonts archlinux

Improve Fonts

Newest

Make your Arch fonts beautiful easily! This is what I do when I install Arch Linux to improve the fonts.

You may consider the following settings to improve your fonts for system-wide usage without installing a patched font library packages (eg. Infinality):

Install some fonts, for example:
sudo pacman -S ttf-dejavu ttf-liberation noto-fonts

@dejanr
dejanr / README
Last active June 11, 2023 20:35
OSX, X11, dwm, urxvt, vim environment
OSX Apps
- Total Spaces, for keeping X11 in different space and faster switching
- MenuAndDockless for hidding topbar menu
X11 - Macports
- sudo port install xorg-server
- sudo port install xinit
- sudo port install terminus-font dejavu-fonts bitstream-fonts
Suckless - suckless.org
@Mithrandir0x
Mithrandir0x / gist:3639232
Created September 5, 2012 16:15
Difference between Service, Factory and Provider in AngularJS
// Source: https://groups.google.com/forum/#!topic/angular/hVrkvaHGOfc
// jsFiddle: http://jsfiddle.net/pkozlowski_opensource/PxdSP/14/
// author: Pawel Kozlowski
var myApp = angular.module('myApp', []);
//service style, probably the simplest one
myApp.service('helloWorldFromService', function() {
this.sayHello = function() {
return "Hello, World!"