Skip to content

Instantly share code, notes, and snippets.

View gistrec's full-sized avatar
🦄
Программирую единорогов

Aleksandr Kovalko gistrec

🦄
Программирую единорогов
View GitHub Profile
@CodeFreezr
CodeFreezr / printenv.groovy
Created April 4, 2018 11:40
Jenkins Groovy to print all env-variables
def env = System.getenv()
env.each{
println it
}
@AntoscencoVladimir
AntoscencoVladimir / ubuntu-php7.2-zts-pthreads
Created February 24, 2018 17:02 — forked from 0xfff/ubuntu-php7.2-zts-pthreads
Installing php-zts on ubuntu 16.04
#####################################################################################
# INSTALL isolated PHP 7.2 ZTS (Thread-safe) with pthreads on Ubuntu 14.04 &16.04 ###
#####################################################################################
0) Possible dependencies
sudo apt-get install libxml2-dev
1) Install necessary bison version
wget http://launchpadlibrarian.net/140087283/libbison-dev_2.7.1.dfsg-1_amd64.deb
@dktapps
dktapps / enable_strict_types.php
Created June 7, 2017 13:38
Hacked-together script to enable strict types in PHP files en masse. Primarily intended for PocketMine-MP.
<?php
declare(strict_types=1);
$startTime = microtime(true);
$iterator = new RecursiveIteratorIterator(new RecursiveDirectoryIterator(__DIR__ . DIRECTORY_SEPARATOR));
foreach($iterator as $file){
if($file->getExtension() === "php"){
$path = $file->getPath() . DIRECTORY_SEPARATOR . $file->getFilename();
{
"body": {
"input": {
"message": "Hello World"
},
"origin": {
"type": "player"
},
"name": "say",
"version": 1,
@ninedraft
ninedraft / README.md
Last active January 29, 2024 23:27
Python udp broadcast client server example.

Python udp broadcast client-server example

⚠️ ❗ ATTENTION ❗ ⚠️

This gist is deprecated and will not be edited in the future. Consider visit ninedraft/python-udp repo. It will not be deleted, however.

⚠️ ❗ ATTENTION ❗ ⚠️

<?php
function gamertag_exists($gamertag)
{
$first_step = explode("<div id=\"Gamerscore\">", file_get_contents("https://gamercard.xbox.com/en-US/$gamertag.card"));
$second_step = explode("</div>", $first_step[1]);
$gamerscore = $second_step[0];
if ($gamerscore != "--") {
return true;
} else {
return false;
@jocopa3
jocopa3 / MCPE_1.1.0.1_Ids.txt
Last active December 20, 2023 07:15
List of all Blocks/Items/Entity Id's in MCPE/Win10 1.1.0.1 and EDU Edition
For advanced users, a syntax highlighter for sublime text and
textmate which makes reading the list easier can be found here:
https://gist.github.com/jocopa3/e4a35921e4f978572e7f45360d231f37
============ Blocks ============
All blocks as found in the 1.1.0.0 Block::initBlocks function.
Block names are the same names used in the /give command.
Name Id Data
@paulirish
paulirish / how-to-view-source-of-chrome-extension.md
Last active April 25, 2024 04:16
How to view-source of a Chrome extension

Option 1: Command-line download extension as zip and extract

extension_id=jifpbeccnghkjeaalbbjmodiffmgedin   # change this ID
curl -L -o "$extension_id.zip" "https://clients2.google.com/service/update2/crx?response=redirect&os=mac&arch=x86-64&nacl_arch=x86-64&prod=chromecrx&prodchannel=stable&prodversion=44.0.2403.130&x=id%3D$extension_id%26uc" 
unzip -d "$extension_id-source" "$extension_id.zip"

Thx to crxviewer for the magic download URL.

@kostaz
kostaz / Compile_Bitcoin_on_Ubuntu_14_04
Last active September 3, 2023 10:31
Compile Bitcoin on Ubuntu 14.04
Assuming the username of the Ubuntu user is "theusername".
Preparation
-----------
```
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install build-essential libtool autotools-dev autoconf pkg-config libssl-dev
@vladimirtsyupko
vladimirtsyupko / gist:10964772
Created April 17, 2014 08:32
Git force pull to overwrite local files
git fetch --all
git reset --hard origin/master
git pull origin master