Skip to content

Instantly share code, notes, and snippets.

Liu Wei lwjef

Block or report user

Report or block lwjef

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@lwjef
lwjef / Disable_Wi-Fi.vbs
Last active Dec 3, 2018 — forked from simply-coded/Disable_Wi-Fi.vbs
Use VBScript to enable, disable, or toggle a connection like your Wi-Fi on and off.
View Disable_Wi-Fi.vbs
'************************
'Name: Disable Connection
'Author: Jeremy England
'Company: SimplyCoded
'Date: 10/01/2016
'************************
Option Explicit
Dim interface, interfaceName, interfaceTarget, available, verb
'Pick the Interface Name you want to disable
@lwjef
lwjef / mkt.sh
Last active Dec 11, 2015
Get Bing mkt code.
View mkt.sh
# http://msdn.microsoft.com/en-us/library/dd251064.aspx
for mkt in "ar-XA" "bg-BG" "cs-CZ" "da-DK" "de-AT" "de-CH" "de-DE" "el-GR" "en-AU" "en-CA" "en-GB" "en-ID" "en-IE" "en-IN" "en-MY" "en-NZ" "en-PH" "en-SG" "en-US" "en-XA" "en-ZA" "es-AR" "es-CL" "es-ES" "es-MX" "es-US" "es-XL" "et-EE" "fi-FI" "fr-BE" "fr-CA" "fr-CH" "fr-FR" "he-IL" "hr-HR" "hu-HU" "it-IT" "ja-JP" "ko-KR" "lt-LT" "lv-LV" "nb-NO" "nl-BE" "nl-NL" "pl-PL" "pt-BR" "pt-PT" "ro-RO" "ru-RU" "sk-SK" "sl-SL" "sv-SE" "th-TH" "tr-TR" "uk-UA" "zh-CN" "zh-HK" "zh-TW"; do
xmlURL="http://www.bing.com/HPImageArchive.aspx?format=xml&idx=0&n=1&mkt=$mkt"
(echo $(curl -s $xmlURL) | grep -o "<urlBase>.\+</urlBase>" | grep "ROW" || echo $mkt) | grep -v "ROW"
done
@lwjef
lwjef / generate-opml.php
Created Apr 11, 2012 — forked from ramsey/generate-opml.php
Generate OPML file from Delicious blogroll tag
View generate-opml.php
#!/usr/local/bin/php
<?php
include_once('getRSSLocation.php');
// del.icio.us username and password
$username = 'your_username';
$password = 'your_password';
$cache_file = '/tmp/delicious-blogroll.xml';
$blogs = array();
@lwjef
lwjef / url2opml.py
Created Apr 9, 2012
create opml from url
View url2opml.py
# coding=utf-8
from BeautifulSoup import BeautifulSoup
import urllib2
import sys, os
reload(sys)
sys.setdefaultencoding('utf-8')
input_file = sys.argv[1]
output_opml = sys.argv[2]
@lwjef
lwjef / twitter_list_to_opml.py
Created Apr 6, 2012 — forked from myles/twitter_list_to_opml.py
A simple python script that creates an OPML file of a Twitter user's lists.
View twitter_list_to_opml.py
#!/usr/bin/env python
"""
A simple script that creates an OPML file of the RSS feeds to
a Twitter user's lists.
python twitter_list_to_opml.py mylesb
Copyright (c) 2010, Myles Braithwaite <me@mylesbraithwaite.com>
All rights reserved.
View mirrior.py
#!/usr/bin/python
from os import listdir, symlink, makedirs
from os.path import basename, join, isdir, isfile, islink, getsize, exists
def all_entry(entry):
return True
def to_bytes(size):
if size.endswith("K"):
return int(size[:-1]) * 1024
@lwjef
lwjef / proxy.sh
Created Nov 13, 2011
goagent and ssh proxy
View proxy.sh
#!/bin/bash
#自行替换 username, host, port,password
python ~/goagent-local/proxy.py & plink -N -v username@host -D 127.0.0.1:port -pw password
View get-fonts.sh
#!/bin/bash
#dir define
myfonts_dir=/usr/share/fonts/truetype/myfonts
remote_dir=http://files.cnblogs.com/DengYangjun
#fonts define
monaco=monaco-linux.ttf
lucida=lucida-console.ttf
msyh=msyh.ttf
You can’t perform that action at this time.