Skip to content

Instantly share code, notes, and snippets.

using Serilog;
using Serilog.Core;
using Serilog.Events;
Log.Logger = new LoggerConfiguration()
.WriteTo.Console(formatProvider:new GuidFormatter())
.Destructure.With<GuidDestructuringPolicy>()
.Destructure.ByTransforming<CustomClass>(Helper.ToString)
.Destructure.ByTransforming<CustomStruct>(Helper.ToString)
.CreateLogger();
<#
.SYNOPSIS
Generates a project change log file.
.LINK
Script posted over:
http://open.bekk.no/generating-a-project-change-log-with-teamcity-and-powershell
#>
# Where the changelog file will be created
#$changelogFile = "%system.teamcity.build.tempDir%\changes_%teamcity.build.id%.txt"
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using DevExpress.Xpf.Grid;
using GUI.Params.DynamicTable.Impl;
from distutils.core import setup
from distutils.dir_util import copy_tree
from py2exe.build_exe import py2exe
import glob
import os
import zlib
import shutil
import time
import shutil
import enthought.tvtk
@sergey-miryanov
sergey-miryanov / gist:7784273
Last active December 30, 2015 05:39
Sampel of flixel bitmap cache usage
private static function getSpriteImpl(filename : String, width : Float,
resize : IResizeBitmapData) : FlxSprite
{
var key = resize.key(filename, width);
if(!FlxG.bitmap.checkCache(key))
{
if(cacheWarning)
{
trace([filename, key, "Not found"]);
}
package;
import flash.display.Sprite;
class Main extends Sprite {
public function new () {
INRES="1680x1050"
OUTRES="1366x768"
FPS="30"
MAXRATE="1000k"
AUDIOBITRATE="60k"
QUAL="veryfast"
STREAM_KEY="STREAM KEY !!!"
URL="rtmp://live.justin.tv/app/$STREAM_KEY"
avconv -v verbose -f x11grab -show_region 1 -s "$INRES" -r "$FPS" \
@sergey-miryanov
sergey-miryanov / gist:5950067
Created July 8, 2013 15:56
generated c++ file
#include <hxcpp.h>
#ifndef INCLUDED_AnalyticsImpl
#include <AnalyticsImpl.h>
#endif
#ifndef INCLUDED_haxe_Log
#include <haxe/Log.h>
#endif
Void AnalyticsImpl_obj::__construct()
package ;
#if macro
import haxe.macro.Context;
import haxe.macro.Expr;
#end
/**
* ...
* @author deep <system.grand@gmail.com>
*/
class Measure
@sergey-miryanov
sergey-miryanov / FinalWindow.hx
Created May 22, 2013 12:34
Example of movable group
package ;
import org.flixel.FlxG;
import org.flixel.FlxSprite;
import org.flixel.FlxGroup;
import org.flixel.FlxTypedGroup;
import Analytics;
class FinalWindow extends FlxGroup implements IGameDialog