Skip to content

Instantly share code, notes, and snippets.

@battleguard
battleguard / DEBUG-CMakeCache.txt
Created April 13, 2018 20:43
CmakeCaches for osgearth vcpkg build
# This is the CMakeCache file.
# For build in directory: c:/Users/battl/OneDrive/Documents/Work/vcpkg/buildtrees/osgearth/x64-windows-dbg
# It was generated by CMake: C:/Program Files/CMake/bin/cmake.exe
# You can edit this file to change values found and used by cmake.
# If you do not want to change any of the values, simply exit the editor.
# If you do want to change a value, simply edit, save, and exit the editor.
# The syntax for the file is as follows:
# KEY:TYPE=VALUE
# KEY is the name of a variable in the cache.
# TYPE is a hint to GUIs for the type of VALUE, DO NOT EDIT TYPE!.
@battleguard
battleguard / out.txt
Created April 13, 2018 19:37
osgearth output log with running build from vcpkg
[osgEarth] [Earth Plugin] Forced load: osgEarthUtil.dll
[osgEarth] [EarthSerializer2] Loaded extension lib "osgPlugins-3.5.6/osgdb_osgearth_viewpoints.dll"
[osgEarth] [Map] cache=none; policy=read-write; bin=no
[osgEarth] hashConfFinal = {
"elevation" : {
"driver" : "tms",
"url" : "http://readymap.org/readymap/tiles/1.0.0/116/"
}
}
@battleguard
battleguard / CONTROL
Last active April 13, 2018 13:15
OsgEarth port for vcpkg
Source: osgearth
Version: 2.9
Description: osgEarth - Dynamic map generation toolkit for OpenSceneGraph Copyright 2015 Pelican Mapping.
Build-Depends: osg
@battleguard
battleguard / rpmbuild-reference.sh
Last active January 2, 2018 15:55
RPM Cheat Sheet
### INSTALLATION ###
# install
rpm -i ${packagename}.rpm
# install with progress
rpm -ivh ${packagename}.rpm
# install in full-on debug mode
rpm -ivvvh ${packagename}.rpm
@battleguard
battleguard / GitCommands.txt
Created March 31, 2017 14:26
GIT COMMANDS
Show Last Commit on each remote branch
for branch in `git branch -r | grep -v HEAD`;do echo -e `git show --format="%ci %cr" $branch | head -n 1` \\t$branch; done | sort -r
Raw
<Style
BasedOn="{StaticResource MetroListView}"
TargetType="{x:Type ListView}">
<Setter Property="ScrollViewer.CanContentScroll" Value="True" />
<Setter Property="ScrollViewer.IsDeferredScrollingEnabled" Value="True" />
<Setter Property="VirtualizingStackPanel.IsVirtualizing" Value="True" />
<Setter Property="VirtualizingStackPanel.VirtualizationMode" Value="Recycling" />
</Style>
@battleguard
battleguard / BigMethodClassTests.cs
Created March 1, 2016 01:55
Showing how to mock a dependency
using System;
using Moq;
using Xunit;
public class BigMethodClass
{
private readonly IBitmapOperations _bitmapOperations;
public BigMethodClass( IBitmapOperations bitmapOperations )
moq.SetupSet( s =>s.ShapeColor = It.IsAny<Color>()).CallBack<Color>( c => moq.SetupGet( s => s.ShapeColor).Returns( c) );
if (radHiragana.IsChecked == true) {
strExpression = "/kana/hirg/aiueo/*";
strExpression = XPaths.aiueo.hirg[randomKana.Next( XPaths.aiueo.hirg .Length)];
GetKana(nav, strExpression);
}
else if (radKatakana.IsChecked == true) {
strExpression = "/kana/kata/aiueo/*";
strExpression = XPaths.aiueo.kata[randomKana.Next( XPaths.aiueo.kata.Length )];
GetKana(nav, strExpression);
}
using NUnit.Framework;
namespace Project
{
public static class FizzBuzz
{
public static string Compute( int inputNumber )
{
if ( inputNumber % 3 == 0 && inputNumber % 5 == 0 )
return "FizzBuzz";