Skip to content

Instantly share code, notes, and snippets.

Slava Vishnyakov slava-vishnyakov

Block or report user

Report or block slava-vishnyakov

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
slava-vishnyakov /
Last active Sep 5, 2017
Laravel Slice Consecutive (like Array#each_cons in Ruby)
View _browser_ide_helper.php
namespace Laravel\Dusk {
class Browser
use Concerns\InteractsWithAuthentication,
View main.go
package main
import (
View gist:b15082e4ec2e520857d7
set -o errexit
echo "Removing exited docker containers..."
docker ps -a -f status=exited -q | xargs -r docker rm -v
echo "Removing dangling images..."
docker images --no-trunc -q -f dangling=true | xargs -r docker rmi

After install run

# start statsd
# start graphite

statsd is on 8125 port graphite is on

View gist:6319786
% ls
foot.c foot.h foot.o toe.c toe.o
% rm * .o
rm: .o: No such file or directory
% ls
slava-vishnyakov / gist:4966944
Created Feb 16, 2013
Nicer foundation.css layout for Rails 3.2
View gist:4966944
<!DOCTYPE html>
<!-- -->
<!--[if lt IE 7 ]><html class="ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]><html class="ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]><html class="ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!-->
<html lang="en"> <!--<![endif]-->
<meta charset="utf-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
slava-vishnyakov / youtube.rb
Created Nov 4, 2012 — forked from jamieowen/youtube.rb
Octopress Youtube plugin...
View youtube.rb
# Example:
# {% youtube %}
require 'cgi'
require 'uri'
module Jekyll
class Youtube < Liquid::Tag
@width = 640
@height = 390
View gist:2909542
* CVE-2012-2122 checker
* You may get differing results with/without -m32
* Joshua J. Drake
#include <stdio.h>
#include <stdlib.h>
View gist:1167509
<?xml version="1.0" encoding="utf-8"?>
<ym:ymaps xmlns:ym=""><Representation xmlns="" xmlns:gml=""><View><boundedBy xmlns=""><Envelope><lowerCorner>30.22437 45.024992</lowerCorner><upperCorner>82.935971 60.008409</upperCorner></Envelope></boundedBy></View><Style gml:id="userobject"><iconStyle><template>#placemark</template></iconStyle><balloonContentStyle><template>#balloon</template></balloonContentStyle></Style><Template gml:id="placemark"><text>&lt;img src="$[metaDataProperty.AnyMetaData.icon]s.png" width="28" heigh="29"/&gt;&lt;font style="font-weight:bold;position:relative;z-index:4;top:-29px;display:block;width:22px;text-align:center" color="$[metaDataProperty.AnyMetaData.color]"&gt;$[metaDataProperty.AnyMetaData.number]&lt;/font&gt;</text></Template><Template gml:id="balloon"><text>&lt;div style="max-width:400px;*width:400px;"&gt;&lt;strong
You can’t perform that action at this time.