Giter VIP home page Giter VIP logo

karankashyap / twitterfontana Goto Github PK

View Code? Open in Web Editor NEW

This project forked from johnnyma/twitterfontana

0.0 2.0 0.0 1.13 MB

An open-source alternative for those flash based Twitter fountains, built using HTML5, CSS (SASS) and Javascript.

Home Page: http://twitterfontana.com

License: MIT License

Ruby 0.09% CoffeeScript 5.25% Makefile 0.09% Python 1.52% HTML 4.86% JavaScript 86.05% CSS 2.15%

twitterfontana's Introduction

TwitterFontana

TwitterFontana is a backchannel visualisation solution for the Twitter Search API v1.1.

The Twitter API connection backend is written in Python & Flask and the Fontana visualisation frontend is written in CoffeeScript and has CSS animations through Compass & SASS.

The HTML for the website is generated using Jade and styling & layout is achieved (mostly) through use of Twitter's Bootstrap 3 framework. The additional theme's are provided by Bootswatch.

Getting started

Alright, so there's some initial preparation and setup to perform to get the project up and running.

Software

First of all, your development machine should be equipped with Python 2.6+ and preferably virtualenv and virtualenvwrapper. This should be no problem on most Linux distributions, fairly easy on OS X and might be somewhat challenging on Windows (I have no experience with Python on Windows).

If you want to be able to edit the CoffeeScript, Jade & SASS files you will also need nodejs + npm, Grunt and Ruby, RubyGems & Bundler to be available.

Prepare

In order to use the Twitter API v1.1 you will need to create a "application" at https://dev.twitter.com/.

Also load up a browser tab with http://randomkeygen.com/, we are going to need a random secret key soon.

Setup

With that out of the way, you can now "install" the project in a virtualenv:

$ mkvirtualenv twitterfontana
$ workon twitterfontana
$ pip install -r requirements.txt

For the frontend requirements also run:

$ npm install
$ bundle install

Then you'll need to create a config file, let's save it as backend/var/conf/fontana.conf.

In this file, enter the credentials for the Twitter application you've created and one of the random "Ft. Knox Passwords":

TWITTER = {
    'consumer-key': 'mYc0nsUm3rK3y',
    'consumer-secret': 'xtH1s1sSuP3rs3cREtX'
}

SECRET_KEY = '%S#cR3T$(~4re>Aws0me{;?='

Verify

Now everything should be set up and configured. We can confirm this by trying to sign in with Twitter.

First start the development server:

$ python backend/src/app.py backend/var/conf/fontana.conf
> * Running on http://127.0.0.1:5000/

Now go to http://localhost:5000/api/twitter/session/new/.

If everything is working correctly you will be redirected to twitter.com and asked to "Authorize your application to use your account".

After confirming access you will be redirected back to a page on the development server with the plain text string "OK".

If you've also installed the frontend requirements you can verify if everything is in working condition by running grunt. You should see some output like this:

$ grunt
> Running "watch" task
> Waiting...

Develop

Cool, you got the initial set up out of the way. Luckily you don't need to do all of this each time you want to work on TwitterFontana. From now on just run these commands to get a development server:

$ workon twitterfontana
$ python backend/src/app.py backend/var/conf/fontana.conf
> * Running on http://127.0.0.1:5000/

And in another terminal window you can keep running Grunt:

$ grunt
> Running "watch" task
> Waiting...

twitterfontana's People

Contributors

aratramba avatar jaap3 avatar jtangelder avatar kaustavha avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.