Skip to content

Instantly share code, notes, and snippets.

View Cretezy's full-sized avatar

Cretezy

View GitHub Profile
@Cretezy
Cretezy / Shout.md
Last active October 13, 2021 01:34
ShoutPlay.js

Simple script to stream a file from Node.js to Icecast (or any libshout compatible server) using nodeshout.

Usage

const shout = ... // Shout instance
const songPath = 'song.ogg';
const playing = play(shout, songPath);
playing.on("finish", ()=>{
  // Do something (e.g.: play next song)
});
@Cretezy
Cretezy / Commands.md
Last active April 17, 2021 15:58
Forgetful Linux Commands

Mostly made for Debian/Ubuntu. Might work with other distributions/setup, be careful.

Spotify scaling

Make Spotify DPI factor of 2.1 (override)

cp /usr/share/applications/spotify.desktop ~/.local/share/applications/
sed -i 's/Exec=spotify %U/Exec=spotify --force-device-scale-factor=2.1 %U/g' ~/.local/share/applications/spotify.desktop
@Cretezy
Cretezy / 420MazeIt.cs
Last active June 25, 2020 01:03
Unity Basic Prim Maze Generator
using UnityEngine;
using System.Collections;
public class Mazer : MonoBehaviour
{
ArrayList walls = new ArrayList ();
ArrayList cells = new ArrayList ();
void MazeIt ()
{
@Cretezy
Cretezy / Tmux cheatsheet.md
Last active July 26, 2016 17:56
All you need to know for tmux

Charles' simple tmux guide

tmux is a better and more modern screen alternative. When refering to PREFIX, it usually is CTRL + B. This can be edited in the tmux config.

Basic Commands

Create session tmux new -s <name>

Attact to session tmux a -t <name>