Skip to content

Instantly share code, notes, and snippets.

View acemir's full-sized avatar
🥁
Tocando o terror 🔊🎵🎶

Acemir Sousa Mendes acemir

🥁
Tocando o terror 🔊🎵🎶
View GitHub Profile
@grymmjack
grymmjack / ANSI.md
Created September 13, 2022 22:00 — forked from fnky/ANSI.md
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@JackDesBwa
JackDesBwa / ascii.rst
Last active October 20, 2023 12:25
A stereoscopic ASCII art

SBS

o===============================================================================oo===============================================================================o
|        .                    .                    .                    .       ||         .                    .                    .                    .      |
|        :                    :                    :                    :       ||         :                    :                    :                    :      |
|        :    .               :    .               :    .               :       ||         :    .               :    .               :    .               :      |
|       .'   .   .           .'   .   .           .'   .   .           .'   .   ||        .'   .   .           .'   .   .           .'   .   .           .'   .  |
@sindresorhus
sindresorhus / esm-package.md
Last active April 7, 2025 16:23
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.
@helton
helton / _credits.md
Last active November 12, 2024 21:23
Charadas
@marcedwards
marcedwards / loadingspinner.pde
Created May 30, 2018 02:25
A loading spinner with 6 dots
// A loading spinner with 6 dots.
// By @marcedwards from @bjango.
//
// Pretty messy and hacked together, but it works. ¯\_(ツ)_/¯
// Created using Processing 3.3.7.
float scaler = 0.24 * 4; // Scale the entire design.
float scalerb = 4; // Scale the entire design more.
int frame = 0;
anonymous
anonymous / visual-crypto.js
Created January 12, 2018 21:16
Visual cryptography using JavaScript
const fs = require('fs');
const PNG = require('pngjs').PNG;
/*
Utilities
=========
*/
const PNG_OPTIONS = {
GRAYSCALE_AND_ALPHA: 4,
@JBlond
JBlond / bash-colors.md
Last active April 7, 2025 20:04 — forked from iamnewton/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
@w3core
w3core / brightnessByColor.js
Created December 8, 2016 08:52
Calculate brightness value by RGB or HEX color
/**
* Calculate brightness value by RGB or HEX color.
* @param color (String) The color value in RGB or HEX (for example: #000000 || #000 || rgb(0,0,0) || rgba(0,0,0,0))
* @returns (Number) The brightness value (dark) 0 ... 255 (light)
*/
function brightnessByColor (color) {
var color = "" + color, isHEX = color.indexOf("#") == 0, isRGB = color.indexOf("rgb") == 0;
if (isHEX) {
var m = color.substr(1).match(color.length == 7 ? /(\S{2})/g : /(\S{1})/g);
if (m) var r = parseInt(m[0], 16), g = parseInt(m[1], 16), b = parseInt(m[2], 16);
@andyshinn
andyshinn / composer.json
Last active February 18, 2024 12:05
Docker Compose PHP Composer Example
{
"require": {
"mfacenet/hello-world": "v1.*"
}
}
@darsain
darsain / svg_sprites.md
Last active February 19, 2025 07:08
How to use SVG sprites in img[src] and css backgrounds

To make this work in CSS:

background: url('images.svg#chart');

or img:

<img src="images.svg#chart">