Table of Contents
Reference sheet by topic: http://ndpsoftware.com/git-cheatsheet.html
Configuration config = new Configuration(); | |
// must select both streams to get oldEvents as well | |
config.getEngineDefaults().getStreamSelection().setDefaultStreamSelector(StreamSelector.RSTREAM_ISTREAM_BOTH); | |
AuditPath.isAuditEnabled = true; | |
// get serviceProvider and register global statement result listener to get notified of all events created or removed | |
epService = EPServiceProviderManager.getDefaultProvider(config); | |
EPServiceProviderSPI spi = (EPServiceProviderSPI) epService; | |
((MetricReportingServiceSPI)spi.getMetricReportingService()).addStatementResultListener(new StatementResultListener() { |
<plugin> | |
<groupId>org.apache.maven.plugins</groupId> | |
<artifactId>maven-compiler-plugin</artifactId> | |
<version>2.4</version> | |
<configuration> | |
<!--<compilerId>javac</compilerId>--> | |
<source>1.6</source> | |
<target>1.6</target> | |
<compilerArgument>-proc:none</compilerArgument> | |
</configuration> |
package utils; | |
import org.springframework.util.MultiValueMap; | |
import java.util.List; | |
import java.util.Map; | |
/** | |
* A Fluent API for manipulating arbitrary maps<br/> | |
*<br/> |
mkdir ~/tmpbuild | |
cd ~/tmpbuild | |
git clone git://github.com/nsidc/vagrant-vsphere.git | |
cd vagrant-vsphere | |
gem build vSphere.gemspec | |
vagrant plugin install vagrant-vsphere-0.0.1 |
@Rule | |
public WireMockRule wireMockRule = new WireMockRule(wireMockConfig() | |
.port(0) | |
.trustStorePath("/path/to/my/keystore.jks") | |
.trustStorePassword("changeit") | |
) { | |
{ | |
enableRecordMappings(); | |
} | |
{ | |
"priority": 10, | |
"request": { | |
"method": "ANY", | |
"urlPattern": ".*" | |
}, | |
"response": { | |
"proxyBaseUrl" : "https://other.com", | |
"additionalProxyRequestHeaders": { | |
"Accept-Encoding": "identity" |
package servletutils; | |
import java.io.IOException; | |
import javax.servlet.FilterChain; | |
import javax.servlet.ServletException; | |
import javax.servlet.http.HttpServletRequest; | |
import javax.servlet.http.HttpServletResponse; | |
import javax.servlet.http.HttpServletResponseWrapper; |
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<artifactId>sample-resttemplate</artifactId> | |
<groupId>com.github.eeichinger.blogs</groupId> | |
<version>1.0-SNAPSHOT</version> | |
<packaging>jar</packaging> |
#!/usr/bin/env python | |
# from https://github.com/sjitech/mac_list_windows_pids/blob/master/lswin.py | |
# requires Quartz framework installed | |
# $pip install pyobjc-framework-Quartz | |
import Quartz | |
#wl = Quartz.CGWindowListCopyWindowInfo( Quartz.kCGWindowListOptionOnScreenOnly | Quartz.kCGWindowListExcludeDesktopElements, Quartz.kCGNullWindowID) | |
wl = Quartz.CGWindowListCopyWindowInfo( Quartz.kCGWindowListOptionAll, Quartz.kCGNullWindowID) |
Reference sheet by topic: http://ndpsoftware.com/git-cheatsheet.html