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
//.m文件的行数 | |
find . -name "*.m" | xargs wc -l | |
//.m .h .xib .c 文件内容总行数 | |
find . -name "*.m" -or -name "*.h" -or -name "*.xib" -or -name "*.c" |xargs grep -v "^$"|wc -l |
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 | |
# Plant rope vim's plugin | |
# This is a script to install or update 'ropevim' | |
# Copyright Alexander Artemenko, 2008 | |
# Contact me at svetlyak.40wt at gmail com | |
function create_dirs | |
{ | |
mkdir -p 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
wget -q -O - https://raw.github.com/gist/2204072/install_tmux_1.6_on_ubuntu_10.04.sh | sudo bash |
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
class UpYunStore(object): | |
APP_NAME = None | |
USERNAME = None | |
PASSWORD = None | |
TMP_PATH = None | |
def __init__(self, uri): | |
assert uri.startswith('http://') | |
self.upyun = UpYun(self.APP_NAME, self.USERNAME, self.PASSWORD) | |
self.prefix = '/' + uri.split('/')[-1] | |
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
#!/usr/bin/python | |
#-*-coding:utf8-*- | |
""" | |
使用说明 | |
1.输入要查找的特定目标文件扩展名,来遍历查找特定扩展名的文件,eg:python find_file.py txt /home | |
2.通过-f指定将结果写入到特定名称的文件,eg:python -f txt_result txt,否则将结果打印在控制台 | |
3.在指定要查找的特定扩展名文件后,指定查找的根目录,eg:python find_file.py txt / | |
""" | |
import sys | |
import os |