This is inspired by A half-hour to learn Rust and Zig in 30 minutes.
Your first Go program as a classical "Hello World" is pretty simple:
First we create a workspace for our project:
This is inspired by A half-hour to learn Rust and Zig in 30 minutes.
Your first Go program as a classical "Hello World" is pretty simple:
First we create a workspace for our project:
#!/usr/bin/env bash | |
if [ "$EUID" -ne 0 ];then | |
>&2 echo "This script requires root level access to run" | |
exit 1 | |
fi | |
if [ -z "${WORDPRESS_DB_PASSWORD}" ]; then | |
>&2 echo "WORDPRESS_DB_PASSWORD must be set" | |
>&2 echo "Here is a random one that you can paste:" |
[ req ] | |
default_bits = 2048 | |
default_keyfile = server-key.pem | |
distinguished_name = subject | |
req_extensions = req_ext | |
x509_extensions = x509_ext | |
string_mask = utf8only | |
[ subject ] |
package main | |
import ( | |
"image" | |
"math" | |
"time" | |
"github.com/faiface/pixel" | |
"github.com/faiface/pixel/pixelgl" | |
"github.com/peterhellberg/plasma" |
<?php | |
class _╯°□°╯︵┻━┻ extends \Exception {} | |
function _╯°□°╯︵┻━┻($message) { | |
throw new _╯°□°╯︵┻━┻($message); | |
} | |
_╯°□°╯︵┻━┻("Flip Table"); |
package main | |
import ( | |
"context" | |
"log" | |
"net/http" | |
"os" | |
"os/signal" | |
"time" | |
) |
import json | |
import datetime | |
import pytz | |
from random import randint | |
import logging | |
import time | |
import redis | |
main_prefix = "bqueues:" |
Dockerfile
that is based on your production image and
simply install xdebug
into it. Exemple:FROM php:5
RUN yes | pecl install xdebug \
&& echo "zend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)" > /usr/local/etc/php/conf.d/xdebug.ini \
package main | |
import ( | |
"math/rand" | |
"testing" | |
"time" | |
) | |
const ( | |
numItems = 100 // change this to see how number of items affects speed |
<?php | |
use Predis\Client; | |
class RedisSession implements SessionHandlerInterface { | |
private $redis; | |
private $keyPrefix; | |
private $maxLifetime; | |
/** |