This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INSERT INTO table (c1, c2, c3) | |
(SELECT 'new c1', c2, c3 | |
FROM table | |
WHERE c1 = 'old c1') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<appender name="GraphiteUdpAppender" type="log4net.Appender.UdpAppender"> | |
<remoteAddress value="graphiteserver.somewhere.com"/> | |
<remotePort value="8125"/> | |
<layout type="log4net.Layout.PatternLayout"> | |
<IgnoresException value="False"/> | |
<conversionPattern value="%property{log4net:HostName}.log4net.%level:1|kv\n"/> | |
</layout> | |
</appender> | |
<!-- Remember to add the appender to the root |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>homebrew.mxcl.jenkins</string> | |
<key>UserName</key> | |
<string>jenkins</string> | |
<key>Nice</key> | |
<integer>-10</integer> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
APPLICATION_IP="192.168.33.1/24" | |
REPLICA_SET="MyReplicaSet" | |
KEY_FILE_PATH="/etc/mongodb/keyfiles" | |
KEY_FILE="mongodb-keyfile" | |
# Make sure this is executed on CentOS 7 | |
OS=`cat /etc/redhat-release | awk {'print $1$4}'` | |
if [ "$OS" != CentOS7* ]; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
After=network.target | |
[Service] | |
ExecStart=/usr/bin/node /var/node/my-service/app.js | |
#Type=forking | |
Restart=always | |
StandardOutput=syslog | |
TimeoutSec=90 | |
SyslogIdentifier=my-service |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- ref: http://media.admob.com/api/v1/docs/ --> | |
<script type="text/javascript" src="http://media.admob.com/api/v1/google_mobile_app_ads.js"></script> | |
<a href="[%DEST_URL_ESC_ESC%]" onclick="admob.opener.openUrl('[%DEST_URL_ESC_ESC%]', false); return false;"> | |
<img border="0" src="[%IMAGESRC%]" width="[%WIDTH%]" height="[%HEIGHT%]"> | |
</a> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
setw -g mode-keys vi | |
set -g mouse on | |
set -g base-index 1 | |
set -g default-terminal "screen-256color" | |
# Panes | |
setw -g pane-base-index 1 | |
set -g pane-border-fg colour236 | |
set -g pane-active-border-fg colour030 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
let gulp = require('gulp'); | |
let sass = require('gulp-sass'); | |
let buildStyles = (src, dest) => { | |
let themes = `${__dirname}/sass/themes`; // convention is _some-theme.scss => @import 'some-theme'; | |
let components = `${__dirname}/sass/components`; | |
return new Promise((resolve, reject) => { | |
gulp.src(src) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Injectable } from '@angular/core'; | |
import StorageService from './storage.service'; | |
@Injectable() | |
export class LocalStorageService extends StorageService { | |
private _storage = localStorage; | |
constructor() { | |
super(); |