原创 Flask

$ export FLASK_APP=hello.py $ flask run --host=0.0.0.0 * Running on http://127.0.0.1:5000/$ export FLASK_APP=hello.py $ 

原创 Django

1) mysite/wsgi.py:用於你的項目的與WSGI兼容的Web服務器入口。2) migrate查看INSTALLED_APPS設置並根據mysite/settings.py文件中的數據庫設置創建任何必要的數據庫表,數據庫的遷移還會

原创 Squid

1, cache確認保證squid不對用戶返回過時數據。在重複使用緩存對象時,squid經常從原始服務器確認它。假如服務器指示squid的拷貝仍然有效,數據就發送出去。否則,squid升級它的緩存拷貝,並且轉發給客戶。2, echo "10

原创 我的友情鏈接

51CTO博客開發

原创 Git Command

git reset --hard HEAD^git reflogGit的版本庫裏存了很多東西,其中最重要的就是稱爲stage(或者叫index)的暫存區,還有Git爲我們自動創建的第一個分支master,以及指向master的一個指針叫HE

原创 awk

1, shell var$ word=world$ echo hello | awk '{ print $1,$word; }'  # Both are treated as awk variables, so it            

原创 tutorial

4. More Control Flow ToolsLoop statements may have an else clause; it is executed when the loop terminates through exhau

原创 python3 cookbook

使用deque(maxlen=N)構造函數會新建一個固定大小的隊列.當新的元素加入並且這個隊列已滿的時候,最老的元素會被移除掉.在隊列兩端插入或者刪除元素時間複雜度都是O(1), 而在列表的開頭插入或刪除元素的時間複雜度爲O(N).當要查找

原创 Git Command

git reset --hard HEAD^git reflogGit的版本庫裏存了很多東西,其中最重要的就是稱爲stage(或者叫index)的暫存區,還有Git爲我們自動創建的第一個分支master,以及指向master的一個指針叫HE

原创 Django

1) mysite/wsgi.py:用於你的項目的與WSGI兼容的Web服務器入口。2) migrate查看INSTALLED_APPS設置並根據mysite/settings.py文件中的數據庫設置創建任何必要的數據庫表,數據庫的遷移還會

原创 thinkpython2

1) Dictionaries have a method called get that takes a key and a default value.    LookupError is a built-in exception us

原创 How To Hide A Processes From Other Users In Linux

Original URL: http://aboredcoder.com/post/how_to_hide_a_processes_from_other_users_in_linux If you're using the Linux ke

原创 我的友情鏈接

51CTO博客開發

原创 Install Apache via Source

#apr cd /tmp/upgrade/ tar zxvf apr-1.4.8.tar.gz  cd apr-1.4.8 ./configure --prefix=/apache/apr make && make install#apr-

原创 MySQL Record

All database options are stored in a text file named           db.opt that can be found in the database          directo