I hereby claim:
- I am juanrossi on github.
- I am juanrossi (https://keybase.io/juanrossi) on keybase.
- I have a public key whose fingerprint is E90E 273F 7821 6415 4657 D6E8 0F8C 9B34 F6F9 317E
To claim this, I am signing this object:
""" | |
Requirements: | |
* requests | |
* sqlite3 | |
* xmltodict | |
* transmission-remote (add with brew or apt-get) | |
* showrss account and rss link | |
""" | |
import os | |
import requests |
I hereby claim:
To claim this, I am signing this object:
def validate_cbu(cbu): | |
""" | |
Validation function for the CBU (Clave Bancaria Unica) | |
Arguments: | |
cbu -- String or int of 22 characters | |
""" | |
cbu = str(cbu) | |
if len(cbu) == 22: |
from fabric.api import env, run, sudo, local, put | |
def production(): | |
"""Defines production environment""" | |
env.user = "deploy" | |
env.hosts = ['example.com',] | |
env.base_dir = "/var/www" | |
env.app_name = "app" | |
env.domain_name = "app.example.com" | |
env.domain_path = "%(base_dir)s/%(domain_name)s" % { 'base_dir':env.base_dir, 'domain_name':env.domain_name } |
""" | |
This fabric file makes setting up and deploying a django application much | |
easier, but it does make a few assumptions. Namely that you're using Git, | |
Apache and mod_wsgi and your using Debian or Ubuntu. Also you should have | |
Django installed on your local machine and SSH installed on both the local | |
machine and any servers you want to deploy to. | |
_note that I've used the name project_name throughout this example. Replace | |
this with whatever your project is called._ |
from __future__ import with_statement | |
from fabric.api import local, settings, abort, run, cd, env, sudo | |
from fabric.colors import green as _green | |
from fabric.colors import yellow as _yellow | |
from fabric.colors import red as _red | |
from fabric.contrib.console import confirm | |
from fabric.contrib.project import rsync_project | |
from fabric.contrib.files import upload_template, exists | |
from fabric.operations import require | |
from fabric.context_managers import prefix |
<!-- jQuery CDN Failsafe to CloudFlare CDN --> | |
<script>window.jQuery || document.write('<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/1.8.3/jquery.min.js"><\/script>');</script> |
$('#selectJob').children().hide(); | |
var sel_list = $('<div id="jobDropdown"><strong class="cta"><span></span></strong><ul></ul></div>'); | |
sel_list.find('span').text($('#selectJob label').text()); | |
$('#selectJob select').children('option').each(function(){ | |
sel_list.children('ul').append('<li>' + $(this).text() + '</li>'); | |
}); | |
$('#selectJob').append(sel_list); | |
$('#jobDropdown').find('li').live('click',function(e){ | |
$('#selectJob select option').eq($(this).index()).attr('selected','selected').siblings('option').removeAttr('selected'); | |
$(this).addClass('selected'); |