This file contains hidden or 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 | |
# ~/bin/chromium.sh | |
# 使用内存文件系统加速 chromium 运行 | |
# 启动前和关闭后同步文件 | |
CMD="chromium" | |
RAM_CACHE_DIR="/dev/shm/$USER-chrome-cache/" | |
DISK_CACHE_DIR="$HOME/.cache/chromium/" |
This file contains hidden or 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
The Chrome Web Store is getting a new look! In the coming weeks, we’ll roll out a new version of the store that requires new images. If you want to provide images in the old sizes, as well, you can do so using the “current store look” tab. | |
Provide images that the store can use to promote your item. Although only the small box image is required, your item might be featured more prominently if you also provide a large box image, a marquee image, or both. | |
Fill the entire region, using square corners and no padding (full bleed). | |
Use a medium or dark background. | |
Avoid text in the image as much as possible. | |
Don’t put white elements along the edges of the image; the edges should be well defined. | |
Don't use a screenshot. | |
Your image should display well when reduced to half size. | |
Note: The size of promotional images in the current Chrome Web Store is different from the size in the new-look store. |
This file contains hidden or 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
2011-12-15 2AM - 2011-12-16 6PM 不定期更新中 | |
1 zgmlhx | |
2 gengdie | |
3 caoliu520 | |
4 taidaonet | |
5 dengbot | |
6 banyilin | |
7 pinggaozhi | |
8 jackbilldarren | |
9 mlhshhs |
This file contains hidden or 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
--- twip/include/twitteroauth.php 2012-02-18 08:13:25.000000000 +0000 | |
+++ twip/include/twitteroauth.php 2012-02-18 08:14:27.000000000 +0000 | |
@@ -219,6 +219,8 @@ | |
if (!empty($postfields)) { | |
$url = "{$url}?{$postfields}"; | |
} | |
+ case 'GET': | |
+ curl_setopt($ch, CURLOPT_HTTPHEADER, array('X-PHX: true')); | |
} | |
This file contains hidden or 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/sh -x | |
SIZE=1270x710 | |
unset SESSION_MANAGER XDG_SESSION_COOKIE DBUS_SESSION_BUS_ADDRESS DESKTOP_SESSION | |
#Xephyr -screen 1270x715 -ac +bs +xinerama -fakexa -dpi 110 :3 & | |
Xephyr -zaphod -screen $SIZE -ac +bs +xinerama -dpi 110 :3 & | |
sleep 1s | |
export DISPLAY=:3 | |
xrdb < ~/.Xresources | |
eval `dbus-launch --sh-syntax` | |
export XMODIFIERS=@im=fcitx QT_IM_MODULE=xim GTK_IM_MODULE=xim ; fcitx & sleep 1 |
This file contains hidden or 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
# -*- coding: UTF-8 -*- | |
# vim:set shiftwidth=4 tabstop=4 expandtab textwidth=79: | |
import re | |
def format_html(html): | |
'''给 html 添加适当换行,以便版本管理 | |
''' | |
html = re.sub('\n?\ ?<(address|blockquote|center|dir|div|dl|fieldset|form|h1|h2|h3|h4|h5|h6|hr|isindex|menu|noframes|noscript|ol|p|pre|table|ul|dd|dt|frameset|li|tbody|td|tfoot|th|thead|tr)([^>]*?)>', '\n<\\1\\2>', html) | |
html = re.sub('</(address|blockquote|center|dir|div|dl|fieldset|form|h1|h2|h3|h4|h5|h6|hr|isindex|menu|noframes|noscript|ol|p|pre|table|ul|dd|dt|frameset|li|tbody|td|tfoot|th|thead|tr)([^>]*?)>\ ?\n?', '</\\1\\2>\n', html) |
This file contains hidden or 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
#!/usr/bin/python | |
# -*- coding: UTF-8 -*- | |
# vim:set shiftwidth=4 tabstop=4 expandtab textwidth=79: | |
from difflib import SequenceMatcher | |
import re | |
from StringIO import StringIO | |
import cgi | |
import base64 |
This file contains hidden or 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
"""CGI-savvy HTTP Server. | |
This module builds on SimpleHTTPServer by implementing GET and POST | |
requests to cgi-bin scripts. | |
If the os.fork() function is not present (e.g. on Windows), | |
os.popen2() is used as a fallback, with slightly altered semantics; if | |
that function is not present either (e.g. on Macintosh), only Python | |
scripts are supported, and they are executed by the current process. |
This file contains hidden or 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
diff --git a/dabr/common/twitter.php b/dabr/common/twitter.php | |
--- a/dabr/common/twitter.php | |
+++ b/dabr/common/twitter.php | |
@@ -376,6 +376,10 @@ function twitter_process($url, $post_dat | |
curl_setopt ($ch, CURLOPT_POST, true); | |
curl_setopt ($ch, CURLOPT_POSTFIELDS, $post_data); | |
} | |
+ if($post_data == false) | |
+ { | |
+ curl_setopt($ch, CURLOPT_HTTPHEADER, array('X-PHX: true')); |
This file contains hidden or 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
diff --git a/dabr/common/twitter.php b/dabr/common/twitter.php | |
--- a/dabr/common/twitter.php | |
+++ b/dabr/common/twitter.php | |
@@ -154,7 +154,7 @@ function long_url($shortURL) | |
function friendship_exists($user_a) { | |
- $request = API_URL.'friendships/show.json?target_screen_name=' . $user_a; | |
+ $request = API_URL.'friendships/show.json?include_entities=true&target_screen_name=' . $user_a; | |
$following = twitter_process($request); |