github-widget, a client-side, complete Github Widget.
Overview
a widget provides your repositores, activities, .. current only repositores part is implemented. for activities, see github-timelime-widget
Live Demo github-widget.heroku.com
Dependency
- Rails3.1
- SproutCore 2.0
- HTML5
- Coffescript
- Sass
INSTALL & USAGE
(optional) use a HTML5 boilerplate
rails new foo --template https://github.com/russfrisch/h5bp-rails/raw/master/h5bp.rb
in Gemfile
gem 'sproutcore-rails', :git => 'git://github.com/GutenYe/sproutcore-rails.git'
gem 'github-api-rails', :git => 'git://github.com/GutenYe/github-api.git', :branch => 'rails'
gem 'github-widget'
in app/assets/javascripts/application.js
//= require github-api
//= require sproutcore
//= require github-widget/projects
in app/assets/stylesheets/application.css
*= require github-widget/projects
in app/views/layouts/applictions.html.erb
<script>
window.github_username = 'gutenye';
</script>
<script type='text/html'>
<%= render 'github-widget/projects.hbs' %>
</script>
...
<%= javascript_include_tag 'appliction' %>
Custom
rails g
this will create a list of source code.
app/assets/javascripts/github-widget/projects.js.coffee
app/assets/stylesheets/github-widget/projects.css.sass.erb
...
Contributing
Set up development environment
cp develop-example develop
cd develop # is a rails3.1 application
# develop and test
# it's import to symlink the outside file into rails project.
cd develop/app/assets/javascripts/github-widget
ln -s ../../../../../app/assets/javascripts/github-widget/projects.js.coffee
Resources
- github-timeline-widget a Github widget that displays your GitHub activity.
- github-api Javascript bindings for the Github API.
- coffee-script Unfancy JavaScript.
- sproutcore20 JavaScript Application Framework.
- sass Sass makes CSS fun again.
- html5-boilerplate starting html/css template. so much goodness baked in by default.