Sep 23, 2013

Linux and Python timezones

$ TZ=KST-9 date
# Thu Oct  3 15:51:21 KST 2013
$ date
# Thu Oct  3 09:51:23 FET 2013
$ ls /usr/share/zoneinfo
Africa      Asia       Canada
.....
$ ls /usr/share/zoneinfo/Europe
Amsterdam  Belgrade    Bucharest  Copenhagen  Helsinki
.....
$ cat /etc/timezone
Europe/Minsk
python -c "import pytz;print pytz.all_timezones"
['Africa/Abidjan', 'Africa/Accra', 'Africa/Addis_Ababa', 'Africa/Algiers',
.....
import datetime, pytz
korea_tz = pytz.timezone('Asia/Seoul')
korea_time = korea_tz.localize(datetime.datetime(2013, 10, 2, 14, 0))
# datetime.datetime(2013, 10, 2, 14, 0, tzinfo=<DstTzInfo 'Asia/Seoul' KST+9:00:00 STD>)
local_time = korea_time.astimezone(pytz.timezone('Europe/Minsk'))
# datetime.datetime(2013, 10, 2, 8, 0, tzinfo=<DstTzInfo 'Europe/Minsk' FET+3:00:00 STD>)
List of time zone abbreviations
List of time zones by country

Sep 19, 2013

Dead snakes

sudo add-apt-repository ppa:fkrull/deadsnakes
sudo apt-get update
sudo apt-get install python2.4 python2.4-dev

Sep 10, 2013

Python API

http://www.pythonapi.com/

Ранжирование языков программирования по их выразительности (Programming languages ranked by expressiveness)

http://dev.by/blogs/main/ranzhirovanie-yazykov-programmirovaniya-po-ih-vyrazitelnosti
http://redmonk.com/dberkholz/2013/03/25/programming-languages-ranked-by-expressiveness/

Если для вашего проекта требуется выразительный язык, по которому сравнительно несложно найти специалистов, обратите пристальное внимание на Python. ;)

Sep 3, 2013

Pythonbrew

This project is no longer under active development.
You are encouraged to try out pyenv instead.