Skip to content

Instantly share code, notes, and snippets.

View Un1q32's full-sized avatar

Un1q32

View GitHub Profile
#include <fcntl.h>
#include <limits.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <unistd.h>
#define CHUNK_SIZE 0xF0000
@Un1q32
Un1q32 / run.sh
Last active August 9, 2024 21:30
#!/bin/sh
# shellcheck disable=2317
servicename="minecraft"
[ "${0%/*}" = "$0" ] && SRVROOT="." || SRVROOT="${0%/*}"
cd "$SRVROOT" || exit 1
SRVROOT="$PWD"
cd "$SRVROOT" || { printf "Server root directory %s not found." "$SRVROOT" ; exit 1; }