Skip to content

Instantly share code, notes, and snippets.

@ezotrank
ezotrank / bench.py
Created September 14, 2014 10:12
simple logsend bench
import os
import time
line_per_second = 25000
cycles = 100
log_file_name = 'test.log'
msg = "test string one\n"
try:
os.remove(log_file_name)
$i; done
/home/ezo/.gvm/gos/go1.3/bin/go get code.google.com/p/goprotobuf/protoc-gen-go
rm -f protocol/*.pb.go
PATH=/home/ezo/Development/forks/influxdb/src/github.com/influxdb/../../../../bin:$PATH /usr/bin/protoc --go_out=. protocol/*.proto
/home/ezo/.gvm/gos/go1.3/bin/go build -o influxdb -tags 'hyperleveldb' github.com/influxdb/influxdb/daemon
# github.com/influxdb/influxdb/protocol
influxdb/protocol/protocol_extensions.go:18: undefined: Point
influxdb/protocol/protocol_extensions.go:24: undefined: Point
influxdb/protocol/protocol_extensions.go:28: undefined: Point
influxdb/protocol/protocol_extensions.go:32: undefined: Point
import ctypes
def crash():
'''\
crash the Python interpreter...
'''
i = ctypes.c_char('a')
j = ctypes.pointer(i)
c = 0
while True:
j[c] = 'a'
$scope.another_agencies = ->
return [] unless $scope.ticket
out = []
angular.forEach $scope.ticket.proposals(), ((proposal) ->
@push(
url: proposal.url()
id: proposal.gate.id
name: proposal.gate.label
productivity: proposal.gate.productivity
price: proposal._price
#!/bin/bash
#
# god Startup script for God monitoring tool.
#
# chkconfig: - 85 15
# description: god monitors your system
#
CONF_DIR=/etc/god/*
PID=/var/run/god.pid
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style>
[ng-cloak], .ng-cloak {
display: none !important;
}
</style>
<title>sdadsd</title>
</head>
Commit: d1554d7664fd93f9cbb963432218e748c7159ddc
Author: Maxim Kremenev <ezotrank@gmail.com>
Date: (9 minutes ago) 2013-03-28 14:27:46 +0700
Subject: Make more clear development and test environment config
* Add automatic logrotate on development and test envs by this trick http://goo.gl/sNLGV
diff --git a/config/environments/development.rb b/config/environments/development.rb
index 6b213b2..c455765 100644
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant::Config.run do |config|
config.vm.box = "ubuntu_12.10_prepare"
config.vm.network :hostonly, "10.0.99.15"
config.vm.customize ["modifyvm", :id, "--memory", 2048]
#config.persistent_storage.location = "/tmp/sourcehdd.vdi"
#config.persistent_storage.size = 1000
end
class Chef
module RAILS
module UserHelpers
def add_user(params)
user_account params['login'] do
action [:create, :modify]
end
end
end
@ezotrank
ezotrank / images.yml
Last active December 10, 2015 05:29
images:
- name: Для двоих
image: images/download.jpg
filters:
- name: Свидание
image: images/download.jpg
- name: СПА
image: images/download.jpg
- name: Готовые подарки