Skip to content

Instantly share code, notes, and snippets.

View ptone's full-sized avatar

Preston Holmes ptone

View GitHub Profile
@stefanfoulis
stefanfoulis / docker_for_mac_disk_default_size.md
Last active June 29, 2023 12:02
How to resize Docker for Mac Disk image and set the default size for new images

Set the default size for new Docker for Mac disk images

UPDATE: The instructions here are no longer necessary! Resizing the disk image is now possible right from the UI since Docker for Mac Version 17.12.0-ce-mac49 (21995).

If you are getting the error: No space left on device

Configuring the qcow2 size cap is possible in the current versions:

# my disk is currently 64GiB
http://fluentconf.com/fluent2014
http://2013.jsconf.us/
http://cssconf.com/
http://events.jquery.org/2013/austin/
http://backboneconf.com/
http://www.ng-conf.org/
http://aneventapart.com/
http://2013.cascadiajs.com/
International:
@ogier
ogier / django-rebase.markdown
Created April 29, 2012 11:55
How to safely rebase all your Django branches.

Here is a quick primer on how to update your branches to track the new django/django git repository. The commands that follow assume that you have your own fork of django/django-old, and that you have this cloned locally, as the origin remote.

Following these steps shouldn't break anything. So long as all your changes are committed and pushed to your fork of django-old already, nothing will affect them. If you are concerned, you can run them in a fresh clone of your fork.

Rebasing

First, add all of the new commits from the new Django repository.

$ git remote add django-new https://github.com/django/django
@pydanny
pydanny / field.html
Created November 8, 2011 16:33
django-uni-form + Twitter Bootstrap
<!-- this usually goes in <project-root>/templates/uni_form/field.html -->
{% if field.is_hidden %}
{{ field }}
{% else %}
<div class="clearfix {% if field.errors %}error{% endif %}">
<label for="{{ field.auto_id }}" {% if field.field.required %}class="requiredField"{% endif %}>
{{ field.label|safe }}{% if field.field.required %}<span class="asteriskField">*</span>{% endif %}
</label>
<div class="input">
@jezdez
jezdez / djpatch.py
Created August 25, 2011 10:21
A helper script to apply patches from Django's trac
#!/usr/bin/env python
"""
Obviously this is only useful if you have to deal with Django's
Trac a lot.
Mostly stolen from Jacob Kaplan-Moss, but improved by Jannis Leidel
and Aymeric Augustin.
Reads a config file at ~/.djpatchrc, e.g.: