1668 Commits

Author SHA1 Message Date
Christopher Allan Webber
cf29e8a824 It's 2012 all up in here 2012-02-02 09:44:13 -06:00
Christopher Allan Webber
95ff15d66e Updating deployment guide so that it can handle the current virtualenv site-packages changes
Now it should try using --system-site-packages and if that
fails (older version) it tries it without the argument.
2012-02-02 09:29:25 -06:00
Elrond
51fba99125 Some small SQL model improvements
- Add default for User.email_verified
- Add default for MediaEntry.state
- Let PathTupleWithSlashes store [] as "NULL",
  but not handling the reverse properly yet!
- Add _id alias field to MediaEntry and MediaComment
2012-01-29 23:02:40 +01:00
Christopher Allan Webber
8a9aa07583 Committing extracted and compiled translations 2012-01-29 13:47:51 -06:00
Christopher Allan Webber
ef9c5bbda6 Committing present MediaGoblin translations before pushing extracted messages 2012-01-29 13:47:36 -06:00
Christopher Allan Webber
76d6323fff Adding a line reminding user to push up commits 2012-01-29 13:32:41 -06:00
Christopher Allan Webber
f62b697eb2 Committing extracted and compiled translations 2012-01-29 13:31:47 -06:00
Christopher Allan Webber
8e5596fb1d Hm, maybe this is better... that didn't fix the stop-in-the-middle issue. 2012-01-29 13:30:32 -06:00
Christopher Allan Webber
f4b206166e Update update_translations script to consider several things conditionally
Specifically, previously if there was nothing to git add, whole script would just die
2012-01-29 13:22:21 -06:00
Elrond
de91730336 Nearly complete support for Tags
These changes allow all of the rest of the code to use tags
in sql as they were used on mongo. It's not efficient at
all, as changing tags usually means to remove all old tags
and adding all new.

The only problem here is: Old slugs for tags are not
removed, because they're shared across all MediaTags and
dropping orphans is not always easy.
2012-01-28 19:32:43 +01:00
Joar Wandborg
ebc0e38239 Resized a test_exif test image. 1.9M is unnecessarily large. 2012-01-28 18:53:36 +01:00
Joar Wandborg
3d0d3bc972 Merge remote-tracking branch 'joar/exif-rebase' 2012-01-28 18:47:01 +01:00
Elrond
d7bec8577e Add develover sql switch
If you want to play with the current state of sql, you need
a switch to turn it on. So here is the super secret
developer switch.

So you want to know where it is?

Here it is:

Create a file mediagoblin/db/sql_switch.py and put one line
in it: "use_sql = True" (or False to disable again). Right,
that's it. If you want to delete it, remember to delete the
*.pyc too.

Be careful not to "git add" it by accident!
2012-01-28 18:36:44 +01:00
Christopher Allan Webber
b4e877ae97 We were using translitcodec and I didn't understand how it worked ;)
My bad!
2012-01-28 11:31:26 -06:00
Christopher Allan Webber
da471f26f2 We aren't using translitcodec anymore. Kill it! 2012-01-28 11:13:03 -06:00
Elrond
3e907d5516 Let some code support "media without slug"
The upcoming SQL database will allow having media without a
slug again. This might especially be useful for API
support, where the uploaded image (media) does not have
*any* information to generate a slug from.

This code change mostly allows the sql backend to have no
slug in its model and improves some parts to properly
handle that.

It specifically does not have any web frontend support to
edit/create MediaEntries with no slug.
2012-01-28 13:53:55 +01:00
Joar Wandborg
9542a2ba07 JavaScript fixes - AGPL headers, etc
- Added AGPL header to comment_show.js, show_password.js
  and geolocation-map.js
- Removed console.log from geolocation-map.js
2012-01-28 01:31:56 +01:00
Joar Wandborg
cd1b836ed4 Scripts and styleshets for geolocation map - Conditional
Scripts and stylesheets for the geolocation map are now
switched on/off with the geolocation map itself.
2012-01-27 02:13:07 +01:00
Joar Wandborg
184dbcdacc Adding previously erroneously gitignored extlib/leaflet/{lib,dist,build}/ files 2012-01-27 01:55:50 +01:00
Joar Wandborg
a8382a3a86 Updated .gitignore due to it blacking out the extlib/leaflet/dist/ directory 2012-01-27 01:52:57 +01:00
Elrond
3c43cfc9f9 Move declarative_base Base into base.py
The base class of all models "Base" should be in base.py.
2012-01-26 23:07:39 +01:00
Elrond
997b419fe3 Add "mediagoblin/templates *.txt" to packaging
Again thanks to Clint Byrum!
2012-01-26 22:14:48 +01:00
Elrond
10196c6811 Drop all buildout things
virtualenv is working for everyone.
No need for the buildout stuff any more.
2012-01-26 22:10:46 +01:00
Elrond
d595374d18 Packaging improvement by Clint Byrum from Debian/Ubuntu
1) MANIFEST.in missed a bunch of things, especially
   config_spec.ini.

2) You need to specify include_package_data=True in
   setup.py to actually activate MANIFEST.in it seems.

Thanks go to Clint Byrum!
2012-01-26 21:33:49 +01:00
Joar Wandborg
cc7ca4da73 Refractored media.html template and related includes
- Added <p> around license part to separate it properly
  from other sidebar content
- Moved exif part to mediagoblin/utils/exif.html
- Moved geolocation map to mediagoblin/utils/geolocation_map.html
2012-01-25 23:53:02 +01:00
Joar Wandborg
63bd7c04bd Acts on feedback from Chris
- Added EXIF tests
- Removed pdb from image processing "ifmain"
- Fixed comment typo in image processing
- Removed unused import in tools.exif
2012-01-25 23:46:11 +01:00
Joar Wandborg
6d9ce47f5c Moved EXIF to sidebar, added conditions for visibility configuration settings 2012-01-25 23:46:11 +01:00
Joar Wandborg
5907222c0b Added exif_visisble and geolocation_map_visible to config_spec 2012-01-25 23:44:59 +01:00
Joar Wandborg
a180ca264e EXIF fixes
- Moved exif functions from mediagoblin.media_types.image.processing
  to mediagoblin.tools.exif
- Moved EXIF.py link from mediagoblin.media_types to mediagoblin.tools.extlib
- Refractored and updated EXIF exctraction and presentation
2012-01-25 23:44:59 +01:00
Joar Wandborg
a020391d90 Removed link to EXIF.py in media_types.image 2012-01-25 23:43:58 +01:00
Joar Wandborg
e8e444a85e EXIF extraction, geolocation map, image rotation
- Images are now rotated based on EXIF image orientation
  (in case the image isn't flipped on X or Y axis or
  correctly oriented, then we do nothing)
- *Always* create a medium.jpg in image.processing, for
  the sake of rotation of display image
- Extract EXIF and GPS tags from images and insert them
  into media_data
- Geolocation map display added to media.html
- EXIF display added, then removed. It is not in this
  revision, although some of it is (the "EXIF" h4
  header). Need to make it presentable, filtering out
  purely robotical tags, perhaps.
2012-01-25 23:43:58 +01:00
Joar Wandborg
836df45dbe Added code for leaflet geolocation map 2012-01-25 23:42:04 +01:00
Joar Wandborg
9bf7563d4c Installed EXIF.py in extlibs/ 2012-01-25 23:42:04 +01:00
Joar Wandborg
c5ba5b0456 Installed leaflet in extlib 2012-01-25 23:42:04 +01:00
Elrond
c47a03b909 Proper url_to_{prev,next} for SQL
Uses complete sqlalchemy syntax now.
2012-01-22 18:41:06 +01:00
Elrond
02ede85826 Create a fully functional get_comments for SQL
Using proper sqlalchemy syntax instead of the emulated
mongo one.
2012-01-22 18:40:42 +01:00
Christopher Allan Webber
ee4fb8125a Canonical license URIS for CC stuff should have a trailing slash. 2012-01-21 17:00:42 -06:00
Christopher Allan Webber
2c1f1fd08b Show the license list in sorted form 2012-01-21 16:58:03 -06:00
Christopher Allan Webber
da6206c4be Oops, I broke teh all rights reserved ;) 2012-01-21 16:56:49 -06:00
Christopher Allan Webber
5d775ebd2f Provided a SORTED_SUPPORTED_LICENSES (but keep the old unsorted dict!) 2012-01-21 16:51:21 -06:00
Christopher Allan Webber
ac014f0424 Convert over the license field, too! 2012-01-21 16:41:07 -06:00
Christopher Allan Webber
2788e6a164 License "all rights reserved" default should be None/NULL, not empty string 2012-01-21 16:40:39 -06:00
Elrond
3c351460e1 Fix unit tests with new license support
Make the license field in the forms optional and let them
properly be defaulted to "".
2012-01-21 19:24:36 +01:00
Aaron Williamson
c8035da197 Added migration for license field, resolved conflict in db/sql/models.py 2012-01-19 22:00:08 -05:00
Elrond
fbad3a9fb9 Add copyright header and a bit of pep8ification
Nearly all the sql files missed a copyright header.
So added it!
And while there fixed a few pep8 things.
2012-01-20 00:17:05 +01:00
Elrond
92edc74e9b Use custom query class
A custom query class allows to add more methods on
queries (read: "cursors").

This custom query class especially adds a .sort with a
calling convention exactly like the mongo one.
Makes a lot of existing code happy!
2012-01-20 00:00:57 +01:00
Aaron Williamson
97ec97dbc7 Minor formatting and syntax fix. 2012-01-18 21:21:49 -05:00
Aaron Williamson
17c23e15e4 Moved get_license_data to mixin.py, added license to sql media model, added translation tags to license template. 2012-01-18 21:07:55 -05:00
Aaron Williamson
291e24f397 Merge branch 'mediagoblin-upstream' into feature544_basic_license_data 2012-01-18 20:40:18 -05:00
Elrond
6fc8af3278 sql/fake.py: Some fake objects/methods to calm the code
sql/fake.py contains some fake classes and functions to
calm the rest of the code base. Or provide super minimal
implementations.

Currently:
- ObjectId "class": It's a function mostly doing
  int(first_arg) to convert string primary keys into
  integer primary keys.
- InvalidId exception
- DESCENING "constant"
2012-01-18 23:35:55 +01:00