Skip to content

Instantly share code, notes, and snippets.

View g3rd's full-sized avatar

Chad Shryock g3rd

  • Washington, DC
View GitHub Profile
$ ./manage.py migrate
/Users/g3rd/Projects/gannett/src/django-cms/cms/publisher/manager.py:5: RemovedInDjango18Warning: `PublisherManager.get_query_set` method should be renamed `get_queryset`.
class PublisherManager(models.Manager):
/Users/g3rd/Projects/gannett/src/django-cms/cms/models/managers.py:15: RemovedInDjango18Warning: `PageManager.get_query_set` method should be renamed `get_queryset`.
class PageManager(PublisherManager):
/Users/g3rd/Projects/gannett/src/cmsplugin-filer/cmsplugin_filer_utils/__init__.py:5: RemovedInDjango18Warning: `FilerPluginManager.get_query_set` method should be renamed `get_queryset`.
class FilerPluginManager(models.Manager):
INSTALLED_APPS = (
'djangocms_text_ckeditor',
'djangocms_admin_style',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.admin',
'django.contrib.sites',
'django.contrib.sitemaps',
'django.contrib.staticfiles',
@g3rd
g3rd / README.md
Last active August 29, 2015 14:08
CMS Plugin w/Site support

Is this the best approach to getting site specific data with a Django CMS plugin?

I've added a site reference to the model and switched the default model manager to the CurrentSiteManager.

So that in forms.py on line 7. When I get the data, I'm only getting data for the current site.

Thoughts?

See:

Keybase proof

I hereby claim:

  • I am g3rd on github.
  • I am webchad (https://keybase.io/webchad) on keybase.
  • I have a public key ASADYKz0By1DDTXwtjx7y0-veUYMNzffmVFI3sIiJMaiJAo

To claim this, I am signing this object:

@g3rd
g3rd / transfer.sh
Created December 22, 2018 16:04
CloudFlare transfer domains
#!/bin/sh
# Get here: https://support.cloudflare.com/hc/en-us/articles/200167836-Where-do-I-find-my-Cloudflare-API-key-
export CF_API_EMAIL=you@example.com
export CF_API_KEY=abc123def456ghi789
# Grabbed mine out of the dashboard url
export CF_ACCOUNT_ID=abc123def456ghi789
for domain in $(cat domains.txt); do \
#!/bin/bash
xhost + 127.0.0.1
docker run --rm -e DISPLAY=host.docker.internal:0 -v /tmp/mydata:/data marcelhuberfoo/sqldeveloper
@g3rd
g3rd / google-chrome.repo
Last active January 6, 2020 18:10
google-chrome.repo
[google-chrome]
name=google-chrome
baseurl=http://dl.google.com/linux/chrome/rpm/stable/$basearch
enabled=1
gpgcheck=1
gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub