Updated requirements and other items in preps of new pinry version

This commit is contained in:
Isaac Bythewood
2013-09-22 03:33:50 +00:00
parent 70a797c5af
commit a4f3adc2df
7 changed files with 24 additions and 15 deletions

View File

@@ -1,4 +1,4 @@
# ![Pinry](http://getpinry.com/theme/images/logo-dark.png) # ![Pinry](https://raw.github.com/pinry/pinry/feeds/logo.png)
The open-source core of Pinry, a tiling image board system for people who The open-source core of Pinry, a tiling image board system for people who
want to save, tag, and share images, videos and webpages in an easy to skim want to save, tag, and share images, videos and webpages in an easy to skim
@@ -52,4 +52,5 @@ for production Django deployment found via Google.
## Current Master Build Status ## Current Master Build Status
[ ![Codeship Status for pinry/pinry](https://www.codeship.io/projects/461ebc50-70be-0130-073a-22000a9d07d8/status?branch=master)](https://www.codeship.io/projects/2005) [ ![Codeship Status for pinry/pinry](https://www.codeship.io/projects/461ebc50-70be-0130-073a-22000a9d07d8/status?branch=master)](https://www.codeship.io/projects/2005)

BIN
logo.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

After

Width:  |  Height:  |  Size: 32 KiB

View File

@@ -31,10 +31,13 @@ class LatestPins(Feed):
Doing this as a fix for Django's not including the domain name in Doing this as a fix for Django's not including the domain name in
enclosure urls. enclosure urls.
""" """
request_type = 'http' try:
if request.is_secure(): request_type = 'https' request_type = 'http'
self.domain_name = ''.join([request_type, '://', if request.is_secure(): request_type = 'https'
get_current_site(request).domain]) self.domain_name = ''.join([request_type, '://',
get_current_site(request).domain])
except:
pass
def items(self): def items(self):
return Pin.objects.order_by('-published')[:15] return Pin.objects.order_by('-published')[:15]

View File

@@ -1,4 +1,5 @@
from .api import * from .api import *
from .forms import * from .forms import *
from .helpers import PinFactoryTest from .helpers import PinFactoryTest
from .views import * from .views import *

View File

@@ -16,6 +16,8 @@ TEST_IMAGE_PATH = 'logo.png'
class UserFactory(factory.Factory): class UserFactory(factory.Factory):
FACTORY_FOR = User
username = factory.Sequence(lambda n: 'user_{}'.format(n)) username = factory.Sequence(lambda n: 'user_{}'.format(n))
email = factory.Sequence(lambda n: 'user_{}@example.com'.format(n)) email = factory.Sequence(lambda n: 'user_{}@example.com'.format(n))
@@ -30,6 +32,8 @@ class UserFactory(factory.Factory):
class TagFactory(factory.Factory): class TagFactory(factory.Factory):
FACTORY_FOR = Tag
name = factory.Sequence(lambda n: 'tag_{}'.format(n)) name = factory.Sequence(lambda n: 'tag_{}'.format(n))
@@ -45,6 +49,8 @@ class ImageFactory(factory.Factory):
class PinFactory(factory.Factory): class PinFactory(factory.Factory):
FACTORY_FOR = Pin
submitter = factory.SubFactory(UserFactory) submitter = factory.SubFactory(UserFactory)
image = factory.SubFactory(ImageFactory) image = factory.SubFactory(ImageFactory)

View File

@@ -4,14 +4,12 @@ from django.contrib.staticfiles.urls import staticfiles_urlpatterns
urlpatterns = patterns('', urlpatterns = patterns('',
url(r'', include('pinry.core.urls', namespace='core')), url(r'', include('pinry.core.urls', namespace='core')),
url(r'', include('pinry.users.urls', namespace='users')), url(r'', include('pinry.users.urls', namespace='users')),
) )
if settings.DEBUG: if settings.DEBUG:
urlpatterns += staticfiles_urlpatterns() urlpatterns += staticfiles_urlpatterns()
urlpatterns += patterns('', urlpatterns += patterns('', url(r'^media/(?P<path>.*)$',
url(r'^media/(?P<path>.*)$', 'django.views.static.serve', { 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT,}),)
'document_root': settings.MEDIA_ROOT,
}),
)

View File

@@ -7,7 +7,7 @@ django-taggit
django-images django-images
django-braces django-braces
django_compressor django_compressor
django-tastypie==0.9.12 django-tastypie==0.9.14
# testing # testing
mock mock