git (4) python (4) devops (3)

How to remove __pycache__ folders and .pyc files

20 February 2018

These folder and files are generated by python. You should add these to your VCS’s ignore file. But if you need to clean these manually, you can do with the command below:

find . | grep -E "(__pycache__|\.pyc|\.pyo$)" | xargs rm -rf

How to block search engines in the nginx

19 February 2018

If you have three layered development structure (local dev, remote staging, remote production) like me, you want to search engines index your staging server. It is easy to prevent search engines from indexing your nginx web server.

add_header  X-Robots-Tag "noindex, nofollow, nosnippet, noarchive";

A journey of a thousand miles begins with a single step

18 February 2018

Some of you may have noticed that I’ve been building my website/blog for a long time. Even some of those have been pestering me about it.

In 2008, I bought my domain to make my personal website. Since then, I have built this website using different kinds of tech stacks, from static to drupal. Well, it took me over 10 years, but finally, I’m here with a flask website. You may find details of my stack below.