Skip to content

Instantly share code, notes, and snippets.

@xcc313
xcc313 / nssmSeleniumInstall.bat
Created July 28, 2017 05:36
nssmSeleniumInstall.bat - Convenience Batch File to install/update a Selenium WebDriver Server (together with IEServer) as Windows Service using NSSM, see http://nssm.cc/.
@echo off
set SERVER_VERSION=2.32.0
set IESERVER_VERSION=2.32.3
:REM This will update the Selenium Server Windows Service with the most recent Version
:REM of Selenium Server.
:REM
:REM Prerequisits:
:REM * Download Selenium Server to Downloads Folder
:REM * Download IE-Server to Downloads Folder and Unzip to Downloads Folder (using suggested name)
// Talking console
//
// Support: http://caniuse.com/#search=SpeechSynthesisUtterance
//
// Copy paste the code into dev console or
// use http://mrcoles.com/bookmarklet/ to create a bookmarklet.
/* ✂️ ......................................................................................... */
if(console.log.name !== 'talkLog') {
console.l = console.log;
@xcc313
xcc313 / Douyu.welcome-reminding.js
Created March 25, 2017 03:34 — forked from g8up/Douyu.welcome-reminding.js
自动语音提醒进入斗鱼房间的观众
javascript:void((function(){
/**
* 功能:自动语音提醒进入斗鱼房间的观众
* 用法:需要[制作成 Chrome 书签](http://pan.baidu.com/s/1skgEosX)
* 版本:v1.0.1
* 日期:2017年2月12日 14:16:12
*/
const $cont = $('#js-chat-cont').find('.c-list');
@xcc313
xcc313 / git-mv-with-history
Created October 13, 2015 03:56 — forked from emiller/git-mv-with-history
git utility to move/rename file or folder and retain history with it.
#!/bin/bash
#
# git-mv-with-history -- move/rename file or folder, with history.
#
# Moving a file in git doesn't track history, so the purpose of this
# utility is best explained from the kernel wiki:
#
# Git has a rename command git mv, but that is just for convenience.
# The effect is indistinguishable from removing the file and adding another
# with different name and the same content.
@xcc313
xcc313 / server.r
Created February 25, 2014 11:13 — forked from wch/server.r
if (!require(quantmod)) {
stop("This app requires the quantmod package. To install it, run 'install.packages(\"quantmod\")'.\n")
}
# Download data for a stock if needed, and return the data
require_symbol <- function(symbol, envir = parent.frame()) {
if (is.null(envir[[symbol]])) {
envir[[symbol]] <- getSymbols(symbol, auto.assign = FALSE)
}