flother Goto Github PK
Name: Matt Riggott
Type: User
Bio: Staff software engineer at Running Tide. Fellow of the Royal Geographical Society. Postgraduate student at Lund University.
Location: Reykjavík, Iceland
Blog: https://www.flother.is/
Name: Matt Riggott
Type: User
Bio: Staff software engineer at Running Tide. Fellow of the Royal Geographical Society. Postgraduate student at Lund University.
Location: Reykjavík, Iceland
Blog: https://www.flother.is/
Introduction ============== Flother is the personal web site for Matt Riggott. It's been through many iterations but now it runs on Python 2.5 and Django 1.1 and is in active development. This is the complete source code, released under the GPL v3.0. It includes six apps that offer a blog, a photo library, geographical locations, a contact form, file uploads, and a Google-powered search. (See "Features" below for more information.) It's fairly specific to my needs but you may find it useful either as a base for your own site or to help you learn Django. You can see the code in action at http://www.flother.com/. For more information, contact me: http://www.flother.com/contact/. Features ========== There are six main apps within the project. The largest is a blog with Akismet-moderated comments. Entries are formatted using Markdown and can be public, private, or draft. Draft entries can be previewed on the site by admin users. Comments can be enabled entry by entry (i.e. one entry can have comments while another doesn't) and use Gravatar for author photos. Next are the two tightly-coupled apps photos and places. Both are currently in active development and will see a full geocoded photo library with an option to import from Flickr. Fourth comes a contact form that emails site admins each time a message is sent. Akismet is used to check whether or not messages are spam — if they are, no email is sent. Messages are stored in the database. Fifth, file uploads. Files of any type can be uploaded and stored via the admin. Thumbnails of images are created and displayed in the admin. A Javascript-based interface for using files in blog entries is provided. And finally, site search. Google's AJAX API is used (server-side) to perform a site-wide search and return results on the site itself. Future work ============= * Google sitemap for blog * Print style sheet * Home page that aggregates site content Requirements ============== The blog requires Python 2.5 and Django 1.1 and depends on the following packages: * Python Imaging Library (http://www.pythonware.com/products/pil/) * Markdown (http://www.freewisdom.org/projects/python-markdown/) * Smartypants (http://web.chad.org/projects/smartypants.py/) * G. Raphaelli's Flickr.API (http://pypi.python.org/pypi/Flickr.API) * South (http://south.aeracode.org/) * Django Compress (http://code.google.com/p/django-compress/) * StaticGenerator (http://github.com/flother/staticgenerator) * Typogrify (http://code.google.com/p/typogrify/) * Participation Graphs (http://github.com/flother/participationgraphs) Note that StaticGenerator is a fork of Jared Kuolt's original, to allow Nginx to server up pre-compressed version of the cache. All these dependencies are listed in a PIP requirements file, requirements.txt, in the root directory of the repository. Installation ============== 1. Clone the read-only repo git clone git://github.com/flother/flother.git 2. Install the dependencies via PIP. (If you use virtualenv you'll want to create a virtual environment and activate it first.) pip install -r requirements.txt If you don't use PIP you should wonder what you've been missing all this time, read up on it, and install it. http://www.b-list.org/weblog/2008/dec/15/pip/ 3. Create a Bash script so you can run the site locally. In the directory flother/flother, create a file called manage.sh and paste in the following three lines: #!/bin/bash export PYTHONPATH=..:$PYTHONPATH django-admin.py $@ --settings=flother.settings.development 4. You'll notice that the settings file Django's using in that script, flother.settings.development, doesn't exist. The settings file that does come with the code, flother.settings.common, is a base settings file containing the shared settings you'll need to run the code. You should create a settings file to use in development that first imports the common settings and then sets its own. Create a file in the flother/flother/settings directory called development.py and paste in the example code from this gist: http://gist.github.com/434537 Note you'll need to add your Akismet API key (to test comments for spam) and your Flickr API key (to download your photos to the app) to these settings. URLs to discover both are included as comments. 5. Create your local database and superuser. cd flother/flother bash manage.sh syncdb bash manage.sh migrate 6. Run the server and head over to the admin. http://localhost:8000/admin/ Note that the front-end won't work until you've created your first blog post. Once you've done that you're ready to rock and roll. http://localhost:8000/blog/ Management commands ===================== There are three management commands in the project; each one is summarised below. For more information read through the code as it's fairly well commented. django-admin.py publishnewentries Because the site can be heavily cached (if you use the Static Generator-created content you can serve the blog static HTML files), any entry published in the future will only actually appear once the cache is flushed, not once its publishing date has passed. To ensure the entry appears as expected, this command will check for entries whose ``published_at`` field is within the last hour. If there are any, the cache will be cleared. This command should be run as an hourly cron job. django-admin.py import_from_flickr Imports public photos from a Flickr account (based on settings.FLICKR_NSID) and stores them and their metadata in the database. This command should be run as regularly if you want to download your photos from Flickr.
Bars is a command-line utility that takes CSV data and outputs a bar chart
Data and scraper for the results of the UK's 2015 general election, taken from the BBC's website
A Nova extension to lint your Python source code with Flake8, and format it with Black
Web extension to stop Microsoft tracking every link you click in emails sent through Office 365
R script to make a ridgeline plot for Conservative/Labour vote share since 1955
Supporting information for a full-semester course on data acquisition and visualisation at Reykjavík University
Personal dotfiles for Bash, Git, Vim, Python, Mutt, and more
Web server for map tiles stored in MBTiles files
Plotting Assignment 1 for Exploratory Data Analysis
The Python- and Django-based code for the website running flother.com. For installation instructions, see the README.
Utilities for working with Excel formulas
Course project for Johns Hopkins University's Getting and Cleaning Data course, October 2015
R package to create ggplot2 charts in the style used on flother.is
Standalone Django app that, before their website redesign, imported gigs listed on the Ripping Records web site into a set of database models.
Data on the potential spring 2014 locations for Glasgow's bike hire scheme (MACH)
Command-line utility to convert HTML tables into CSV files
Data Package containing records for all and every building in Iceland
Testing user location tracking with Mapbox GL JS
Python code to discover the nearest planet to Earth. R code to plot it
A Nova extension to add syntax highlighting for Git commit messages
A Panic Nova extension for todo and fixme management.
Django app with a template tag to allow you to include sparklines of the 52-week commit history for a project on Github
CLI for full-text search of PDF, PPT, and XLS files using Elasticsearch
Repository for Programming Assignment 2 for R Programming on Coursera
Peer Assessment 1 for Reproducible Research
Data on the 11,500+ athletes and 306 events at the Rio Olympics. Includes medals tallies
Create a spritesheet from a set of SVG images
A more useable copy of the official Icelandic street address database
Library to layout text for display on SVG or Canvas.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.