Skip to content

Instantly share code, notes, and snippets.

# MPlayer M2TS troubleshooting
# larger number
mplayer -tsprobe nnn
# force libavformat
mplayer -demuxer lavf
# ffmpeg-mt
mplayer -lavdopts threads=3 -vf yadif
browser.taskbar.previews.enable
# set static IP
netsh interface ip set address eth0 static 192.168.11.1 255.255.255.252
# set dhcp
netsh interface ip set address eth0 dhcp
# set MTU
netsh interface ipv4 set subinterface "Local Area Connection" mtu=9000 store=persistent
Imports System
Imports EnvDTE
Imports EnvDTE80
Imports EnvDTE90
Imports EnvDTE90a
Imports EnvDTE100
Imports System.Diagnostics
Public Module IndentStyle
Public Sub Space2()
<?xml version="1.0" encoding="utf-8"?>
<config version="1">
<var name="HIDE_MISSING">true</var>
<var name="SoftBase">${var:KU_SHELL_EXTENSION_DRIVE}\software</var>
<var name="IconDir">${var:KU_SHELL_EXTENSION_DIR}\icons</var>
<var name="KuUtils">${var:SoftBase}\_util_\KuUtils</var>
<var name="CmdHide">${var:KuUtils}\CmdHide.exe</var>
<var name="Cmd32">${var:SysDir32}\cmd.exe</var>
<var name="Cmd64">${var:SysDir64}\cmd.exe</var>
@echo off
call "%ProgramFiles(x86)%\Microsoft Visual Studio 10.0\VC\vcvarsall.bat" x86
"%~dp0configure.exe" -debug-and-release -opensource -ltcg -no-qt3support -plugin-sql-odbc -plugin-sql-mysql -plugin-sql-psql -plugin-sql-sqlite -platform win32-msvc2010
Private Sub DocumentEvents_Documents(ByVal document As EnvDTE.Document) _
Handles DocumentEvents.DocumentSaved
Try
' Remove all the trailing whitespaces.
If vsFindResult.vsFindResultReplaced = _
DTE.Find.FindReplace( _
vsFindAction.vsFindActionReplaceAll, _
"{:b}+$", _
vsFindOptions.vsFindOptionsRegularExpression, _
String.Empty, _
@JackieKu
JackieKu / Rakefile
Created October 21, 2010 02:04 — forked from andreyvit/Rakefile
require 'rake/clean'
HAML = FileList['**/*.haml']
LESS = FileList['**/*.less']
COFFEE = FileList['**/*.coffee']
MINJS = FileList['**/*.js']
HTML = HAML.ext('html')
CSS = LESS.ext('css')
JS = COFFEE.ext('js')

Multiple files

  • :e# C-^

    toggle between two buffers

  • :bn :bp :br :bf :bl

    walk through multiple buffers

1. Given a line of text $string, how do you use "regular expression"
to strip all html tags from it? (Please specify the language you use)
2. A relational database table "T" has 3 columns "img", "p", and "client". Please write a simple script language to parse the following script and insert the value of the parameters into table "T".
"GET /search?img=001&p=dvd&client=aa"
3. What's the output of the following MapReduce program?
[data]
monkey