Skip to content

Instantly share code, notes, and snippets.

View zerkms's full-sized avatar

Ivan Kurnosov zerkms

View GitHub Profile
@zerkms
zerkms / bb_test.go
Last active September 13, 2019 00:24
package bb
import (
"strings"
"testing"
)
var str = `well they might wear classic reeboks
or knackered converse
or tracky bottoms tucked in socks
<?php
/*
* This file is part of the webmozart/assert package.
*
* (c) Bernhard Schussek <bschussek@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
FROM php:7.2.19-cli
RUN set -eux; \
apt update; \
apt install --no-install-recommends unzip; \
rm -rf /var/lib/apt/lists/*; \
cd /usr/src; \
curl -o sqlite.zip https://www.sqlite.org/2017/sqlite-preprocessed-3200100.zip; \
unzip sqlite.zip; \
rm sqlite.zip; \
@zerkms
zerkms / readme.md
Last active December 10, 2018 02:52
refrag + tcpreplay with libdnet (so that it was possible to refragment packets captured with pcap while replaying them with tcpreplay)

refrag

mkdir -p ~/src/
cd ~/src/
git clone https://github.com/zerkms/ipfrag
cd ipfrag
sudo apt install make virtualenv python-minimal
make

source ./venv/bin/activate

### Keybase proof
I hereby claim:
* I am zerkms on github.
* I am zerkms (https://keybase.io/zerkms) on keybase.
* I have a public key whose fingerprint is 5BE7 0772 7FBC 3C36 D140 0C6B A120 FC53 F90E AC2A
To claim this, I am signing this object:

Setting up RhodeCode on Ubuntu Server 12.04

Preparation

  1. Install Ubuntu Server.
  2. Update Ubuntu with the commands:
<!--
Copyright 2004 ThoughtWorks, Inc
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
#! /bin/sh
### BEGIN INIT INFO
# Provides: skeleton
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Example initscript
# Description: This file should be used to construct scripts to be
# placed in /etc/init.d.
@zerkms
zerkms / CellEditingF2.js
Last active October 4, 2015 03:48
Extjs grid CellEditing triggered by F2 plugin
/*
* ExtJS Grid plugin that triggers CellEditing on F2 in addition to clicks and Enter
*
* License: GPL
* Author: Ivan Kurnosov
*/
Ext.define('Ext.grid.plugin.CellEditingF2', {
alias: 'plugin.celleditingf2',
extend: 'Ext.grid.plugin.CellEditing',
requires: ['Ext.grid.plugin.CellEditing'],