Install Python
$ brew install readline sqlite gdbm
$ brew install python --universal --framework
$ python --version
Python 2.7
Symlinks...
| #!/bin/bash | |
| web_service='nginx' | |
| config_file="/usr/local/etc/le-renew-webroot.ini" | |
| le_path='/opt/letsencrypt' | |
| exp_limit=30; | |
| if [ ! -f $config_file ]; then | |
| echo "[ERROR] config file does not exist: $config_file" |
Install Python
$ brew install readline sqlite gdbm
$ brew install python --universal --framework
$ python --version
Python 2.7
Symlinks...
Install Python
$ brew install readline sqlite gdbm
$ brew install python --universal --framework
$ python --version
Python 2.7
Symlinks...
| import os | |
| #путь до settings.py | |
| PROJECT_DIR = os.path.dirname(os.path.realpath(__file__)) | |
| #функция которая поднимается на один уровень вверх до того места где находятся папки со статикой и медиа | |
| def j(*args): | |
| return os.path.join(PROJECT_DIR, '..', *args) | |
| MEDIA_ROOT = j('media') | |
| MEDIA_URL = '/media/' |
| #! /bin/bash | |
| # Redmine | |
| # Maintainer: @randx | |
| # App Version: 2.3 | |
| ### BEGIN INIT INFO | |
| # Provides: redmine | |
| # Required-Start: $local_fs $remote_fs $network $syslog | |
| # Required-Stop: $local_fs $remote_fs $network $syslog |
Attention: if you attempt to fork this gist, github will think that you are a spammer and you will have to confirm that you are human with them. Apparantly there are too many links in this list. Also I update it rather frequently (see revisions on the left), so it's probably wise to not fork it anyway.
| [[+icon]]<br> | |
| [[+temp_c]]<br> | |
| [[+condition]]<br> | |
| [[+wind_condition]]<br> | |
| [[+humidity]] |
| <?php | |
| if(!isset($city)){ | |
| $city="Moskow"; | |
| } | |
| if(!isset($lang)){ | |
| $lang="ru"; | |
| } | |
| $requestAddress = "http://www.google.com/ig/api?weather=$city&oe=utf8&hl=$lang"; | |
| $xml_str = file_get_contents($requestAddress,0); | |
| $xml = new SimplexmlElement($xml_str); |