Skip to content

Instantly share code, notes, and snippets.

View carlmartus's full-sized avatar

Martin Sandgren carlmartus

View GitHub Profile

sample docker compose

version: '3'
services:
  blob-consumer:
    container_name: article-blob-consumer-container-compose
    image: blob-consumer-image:1.0
    build:
 context: .
@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
@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
@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
@lifthrasiir
lifthrasiir / why-large.md
Last active September 27, 2017 14:17
Why is a Rust executable large? (DRAFT)

Suppose that you are a programmer primarily working with compiled languages. Somehow you’ve got tired of those languages, there may be multiple valid reasons, and heard of a trendy new programming language called Rust. Looking at some webpages and the official forum, it looks great and you decides to try it out. It seems that Rust was a bit cumbersome to install in the past, but thanks to rustup the problem seems gone by now. Cargo seems to be great, so you follow the first sections of the Book and put a small greeting to the new language:

fn main() {
    println!("Hello, world!");
}

Amazingly cargo run runs without a hassle. It is kind of a miracle as you used to configure the build script, Makefile, projects or whatever before building things. Impressed, you realize that the executable is available in target/debug/hello. You instinctively type ls -al out (or is it dir?) and

@PurpleBooth
PurpleBooth / README-Template.md
Last active May 6, 2024 07:22
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

Systemd

sample.service file you have to copy it to /etc/systemd/system

Set it to auto start

sudo systemctl enable sample.service

Troubleshoot

@mygnu
mygnu / libxml_parsig.c
Created January 27, 2014 01:22
libxml2 test
/* Code: */
#include <libxml/parser.h>
#include <libxml/xpath.h>
#include <stdio.h>
xmlDocPtr
getdoc (char *docname)
{
xmlDocPtr doc;
doc = xmlParseFile(docname);
@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.
*/