Skip to content

Instantly share code, notes, and snippets.

@mariosv
mariosv / boost_geometry_within_bad_result
Last active August 29, 2015 14:01
[boost::geometry] within() invalid result
#include <iostream>
#include <boost/geometry.hpp>
#include <boost/geometry/geometries/geometries.hpp>
#include <boost/geometry/io/wkt/wkt.hpp>
#include <boost/geometry/strategies/cartesian/point_in_poly_franklin.hpp>
#include <boost/geometry/strategies/cartesian/point_in_poly_crossings_multiply.hpp>
namespace bg = boost::geometry;
@mariosv
mariosv / monitor_and_run.py
Last active August 29, 2015 13:56
Script to monitor file modifications and run commands
#!/usr/bin/env python
""" Monitors modifications of files with the given file extensions
recursively under the current directory and runs the supplied command.
Usage:
monitor_and_run <cmd> <ext1> [[ext2]...]
For example:
monitor_and_run make .tex