A rust implementation of the pipe operator.
# Using cargo run
cargo run -- --in curl https://systemglitch.me --out grep SystemGlitch
#!/bin/bash | |
# Converts PNG images to WEBP | |
# If no argument is given, all PNG images in the | |
# working directory are converted. | |
# Otherwise only the files given as arguments will be | |
# converted. | |
files="$@" | |
if [ $# -eq 0 ]; then |
package main | |
// This is an example of a resilient worker program written in Go. | |
// | |
// This program will run a worker, wait 5 seconds, and run it again. | |
// It exits when SIGINT or SIGTERM is received, while ensuring any ongoing work | |
// is finished before exiting. | |
// | |
// Unexpected panics are also handled: program won't crash if the worker panics. | |
// However, panics in goroutines started by the worker won't be handled and have |
FROM golang:1.15-alpine | |
LABEL maintainer="Jérémy LAMBERT (SystemGlitch) <[email protected]>" | |
RUN apk update && apk upgrade && apk add --no-cache git openssh | |
RUN go get github.com/cespare/reflex | |
ENV DOCKERIZE_VERSION v0.6.1 | |
RUN wget https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-alpine-linux-amd64-$DOCKERIZE_VERSION.tar.gz \ | |
&& tar -C /usr/local/bin -xzvf dockerize-alpine-linux-amd64-$DOCKERIZE_VERSION.tar.gz \ |
import png #pip3 install pypng | |
import math | |
class Heighway: | |
def __init__(self, size = 1000): | |
self.size = size | |
def init_grid(self): | |
self.grid = [] |
FROM php:7.2-fpm | |
RUN apt-get update && apt-get install -y \ | |
git \ | |
zip \ | |
curl \ | |
sudo \ | |
unzip \ | |
libicu-dev \ | |
libbz2-dev \ |
pragma solidity ^0.5.6; | |
contract Monopoly { | |
struct Player { | |
uint balance; | |
bool exists; | |
} | |
uint constant contribution = 1 ether; |
# Script to generate a new block every minute | |
# Put this script at the root of your unpacked folder | |
#!/bin/bash | |
echo "Generating a block every minute. Press [CTRL+C] to stop.." | |
address=`./bin/bitcoin-cli getnewaddress` | |
while : | |
do |
#include <stdlib.h> | |
#include "LinkedList.h" | |
/** | |
* Creates an empty linkedlist_t. head is set to NULL and length to 0. | |
*/ | |
linkedlist_t *linkedlist_init() { | |
linkedlist_t *list = malloc(sizeof(linkedlist_t)); | |
if(list == NULL) return NULL; | |
list->length = 0; |
//This code allows you to know if the player is critical hitting | |
//This has to be used in EntityDamageByEntityEvent | |
//"p" is the Player variable | |
boolean crit = ((CraftPlayer) p).getHandle().fallDistance > 0.0F && !((CraftPlayer) p).getHandle().onGround && !((CraftPlayer) p).getHandle().n_() && !((CraftPlayer) p).getHandle().isInWater() && !((CraftPlayer) p).getHandle().hasEffect(MobEffects.BLINDNESS) && !((CraftPlayer) p).getHandle().isPassenger(); | |
crit = crit && !((CraftPlayer) p).getHandle().isSprinting(); |