Skip to content

Instantly share code, notes, and snippets.

View carlmartus's full-sized avatar

Martin Sandgren carlmartus

View GitHub Profile
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active May 18, 2024 11:00
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@PurpleBooth
PurpleBooth / README-Template.md
Last active May 17, 2024 09:42
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@spion
spion / a-warning.md
Last active March 25, 2024 03:01
C++ versus V8 versus luajit versus C benchmark - (hash) tables

Warning

This benchmark has been misleading for a while. It was originally made to demonstrate how JIT compilers can do all sorts of crazy stuff to your code - especially LuaJIT - and was meant to be a starting point of discussion about what exactly LuaJIT does and how.

As a result, its not indicative of what its performance may be on more realistic data. Differences can be expected because

  1. the text will not consist of hard-coded constants
@dashed
dashed / github-pandoc.css
Created September 26, 2013 13:42
GitHub-like CSS for pandoc standalone HTML files (perfect for HTML5 output). Based on Marked.app's GitHub CSS. Added normalize.css (v2.1.3) in the prior to GitHub css.
/*! normalize.css v2.1.3 | MIT License | git.io/normalize */
/* ==========================================================================
HTML5 display definitions
========================================================================== */
/**
* Correct `block` display not defined in IE 8/9.
*/
@max-mapper
max-mapper / bibtex.png
Last active March 10, 2024 21:53
How to make a scientific looking PDF from markdown (with bibliography)
bibtex.png
@arq5x
arq5x / test.sh
Last active November 30, 2023 12:50
Compress and then Decompress a string with zlib.
# compile
$ g++ zlib-example.cpp -lz -o zlib-example
# run
$ ./zlib-example
Uncompressed size is: 36
Uncompressed string is: Hello Hello Hello Hello Hello Hello!
----------
@suyash
suyash / client.c
Created January 2, 2017 15:53
UDP echo client-server implementation
#include <arpa/inet.h>
#include <stdio.h>
#include <string.h>
#include <sys/socket.h>
#include <unistd.h>
int main() {
const char* server_name = "localhost";
const int server_port = 8877;
@VadimBrodsky
VadimBrodsky / install-unrar-nonfree-raspbian.sh
Created October 8, 2016 18:30
Get Unrar Nonfree on Raspbian for the Raspberry PI
# As per this guide -- http://raspberrypi.stackexchange.com/questions/3617/how-to-install-unrar-nonfree#3618
# Uninstall unrar-free.
sudo apt-get remove unrar-free
# Make sure you have a source repository by editing /etc/apt/sources.list.
cat /etc/apt/sources.list
# Sync the apt database.
sudo apt-get update
@kvark
kvark / rust-graphics.md
Created September 9, 2017 02:58
Rust Graphics Libraries Navigator

What sort of graphics do you need?

  • 2D only. All you need is...
  • 3D for sure. Do you like making your hands dirty?
  • Sometimes: amethyst

sample docker compose

version: '3'
services:
  blob-consumer:
    container_name: article-blob-consumer-container-compose
    image: blob-consumer-image:1.0
    build:
 context: .