This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # make sure requirements.txt is up to date with every commit | |
| # by comparing the output of pip freeze | |
| pip freeze | diff requirements.txt - > /dev/null | |
| if [ $? != 0 ] | |
| then | |
| echo "Missing python module dependencies in requirements.txt. Run 'pip freeze > requirements.txt' to update." | |
| exit 1 | |
| fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ,:',:`,:' | |
| __||_||_||_||__ | |
| ____["""""""""""""""]____ | |
| \ " '''FEATURE'''''''''' \ | |
| ^~^~^^~^~^~^~^~^~^~^~^~^~^~^~~^~^~^^~~^~^ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ================================== | |
| ||||AT NETRW DIRECTORY LISTING|||| | |
| ================================== | |
| press % at file selection screen(not sure what that's called) to create and open new file | |
| press d for new directory |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #at develop branch | |
| git tag | |
| git flow release start [ver number] | |
| git flow release finish [ver number] | |
| #will end up at master, update it by pulling if necessary, and then push | |
| fab deploy:prod | |
| fab uwsgi:prod,restart | |
| ./manage.py migrate --list --settings=greedychimp.settings.prod | |
| #and migrate |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {% extends "base.html" %} | |
| {% block title %}Test django-paypal cart{% endblock %} | |
| {% block content %} | |
| <h1>Testing django-paypal cart</h1> | |
| {{ form.render }} | |
| {% endblock %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Ctrl + A Go to the beginning of the line you are currently typing on | |
| Ctrl + E Go to the end of the line you are currently typing on | |
| Ctrl + L Clears the Screen, similar to the clear command | |
| Ctrl + U Clears the line before the cursor position. If you are at the end of the line, clears the entire line. | |
| Ctrl + H Same as backspace | |
| Ctrl + R Let’s you search through previously used commands | |
| Ctrl + C Kill whatever you are running | |
| Ctrl + D Exit the current shell | |
| Ctrl + Z Puts whatever you are running into a suspended background process. fg restores it. | |
| Ctrl + W Delete the word before the cursor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if there's a migration problem and you could not rollback nor advance the migration, try doing this | |
| All the migrations, that have previously been triggered are stored in the database in a table called south_migrationhistory. | |
| The migrations that are saved inside this table are not going to be triggered anymore. So if you want to run them again, you have to delete their records from that table. | |
| If you're using MySQL this can be done through PhpMyAdmin, if using PgSQL, through PgAdmin III. You can also do this through the Django Project management shell. | |
| python manage.py shell | |
| from south.models import MigrationHistory |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def test_paypal_callback(self): | |
| response = self.client.login(username=self.user.email, password='foz') | |
| self.assertTrue(response) | |
| # create post params simulation from paypal | |
| order = OrderFactory(event=self.event, cart=self.cart, | |
| payment_method=self.payment_method) | |
| total = '%.2f' % self.total | |
| post_param = { |
This file has been truncated, but you can view the full file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 'use strict'; | |
| var COMPILED = !0, goog = goog || {}; | |
| goog.global = this; | |
| goog.DEBUG = !1; | |
| goog.LOCALE = "en"; | |
| goog.provide = function (a) { | |
| if (!COMPILED) { | |
| if (goog.isProvided_(a)) | |
| throw Error('Namespace "' + a + '" already declared.'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [item for item in items if cond] | |
| [item if cond else something_else for item in items] |