Skip to content

Instantly share code, notes, and snippets.

@thingsiplay
thingsiplay / proton
Last active December 10, 2024 18:05
Proton script
#!/bin/sh
# Execute Windows programs with Proton from Steams installation folder, without
# starting Steam client.
#
# 1. Create a directory for Proton environment to run in. As an example make a
# folder "proton" in your home directory. This folder must exist in order
# to make Proton work.
#
# 2. Point the variable "env_dir" in this script to that folder or...
@olasd
olasd / stream_to_youtube.sh
Created March 28, 2014 19:58
Stream video to youtube via ffmpeg
#! /bin/bash
#
# Diffusion youtube avec ffmpeg
# Configurer youtube avec une résolution 720p. La vidéo n'est pas scalée.
VBR="2500k" # Bitrate de la vidéo en sortie
FPS="30" # FPS de la vidéo en sortie
QUAL="medium" # Preset de qualité FFMPEG
YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2" # URL de base RTMP youtube
@tejainece
tejainece / marshall_slice_map_in_struct.go
Last active November 12, 2021 10:05
Marshall slice and map members of a struct into JSON in Golang.
package main
import (
"fmt"
"encoding/json"
)
type Data struct {
IntF int
StringF string