This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import asyncio | |
import socket | |
async def handle_echo(reader, writer): | |
addr = writer.get_extra_info('peername') | |
while True: | |
data = await reader.read(4096) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Stop all containers | |
docker stop $(docker ps -a -q) | |
# Delete all containers | |
docker rm $(docker ps -a -q) | |
# Delete all images | |
docker rmi $(docker images -q) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
yum -y install centos-release-scl which devtoolset-7-gcc* libxml2-devel zlib-devel | |
scl enable devtoolset-7 bash | |
gcc --version | |
cat >/tmp/llvm.sh <<'EOL' | |
#LLVMDIR="/usr/local/src/llvm" | |
#build in ramdisk if it's >= 8GB | |
LLVMDIR="/run/llvm" | |
LLVMVER="8.0.0" | |
TEST_CC="/opt/rh/devtoolset-7/root/usr/bin/cc" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) diskutil eraseDisk FAT32 "WINDOWS10" MBRFormat disk3 | |
2) copy files from iso to usb | |
3) boot in UEFI mode from flash |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Юрий Кузнецов | |
пианист, композитор, заслуженный деятель искусств Украины | |
Прем’єр-міністру України пані Ю. Тимошенко | |
Міністру культури і туризму України пану В. Вовкуну | |
Міністру освіти та науки України пану І. Вакарчуку | |
Голові Комітету з питань освіти та науки Верховної Ради України пану В. Полохало |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Homebrew has done away with options in all of their core formulas | |
# discussion on this change here: https://github.com/Homebrew/homebrew-core/issues/31510 | |
# install it like this: | |
brew install https://gist.githubusercontent.com/rashkur/cfcc377bd378fb709dff949fcf5bb889/raw/3333ea8f44cee6ed54a1a134dab99599dc32b6ae/ffmpeg.rb \ | |
--with-aom \ | |
--with-chromaprint \ | |
--with-fdk-aac \ | |
--with-fontconfig \ | |
--with-freetype \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// checking bindings snippets | |
if (binding.hasVariable('superVariable')) { | |
// your code here | |
} | |
An easy solution to this is the following: | |
if (binding.variables.containsKey("bindingVar")) { | |
// do something | |
} | |
Or if you’d like to get a null value for an optional binding: |
OlderNewer