Skip to content

lokka/lokka-org

Folders and files

NameName
Last commit message
Last commit date

Latest commit

d6f8849 · Apr 5, 2013
Jul 25, 2012
Feb 9, 2012
Feb 15, 2013
Mar 7, 2013
Apr 5, 2013
Feb 15, 2013
Apr 24, 2011
Jan 4, 2012
Feb 28, 2013
Feb 28, 2013
Feb 28, 2013
Aug 24, 2010
Mar 21, 2013
Feb 12, 2012
Nov 21, 2010
Feb 28, 2013
Sep 20, 2012
Feb 28, 2013
Mar 21, 2013
Jan 30, 2011
Oct 9, 2010

Repository files navigation

Lokka

CMS written in Ruby for cloud computing.

Features

  • Performs in the cloud environment such as Google App Engine and Heroku as well as Windows, Mac, and Linux.
  • Designed with reference to WordPress for WordPress users to easily understand.
  • Easy installation
  • Easy to create a theme for designers.
  • A clear plug-in API for Rubyists

Installation

$ git clone git://github.com/lokka/lokka.git
$ cd lokka
$ bundle install --without=production:test
$ bundle exec rake db:setup
$ bundle exec rackup

View at: http://localhost:9292/

Deploy to Heroku

$ git clone git://github.com/lokka/lokka.git
$ cd lokka
$ heroku create
$ git push heroku master
$ heroku addons:add heroku-postgresql:dev
$ heroku pg:info | head -n1 | awk '{print $2}' | xargs heroku pg:promote
$ heroku rake db:setup
$ heroku open

or just copy and paste

\curl -L http://bit.ly/ROX0lk | bash -s

to your terminal

Test

$ rake spec

How to make a theme

Make a directory for theme in public/theme and you need to create entries.erb and entry.erb at least. (erb, haml and slim is available.)

Index page

public/theme/example/entries.haml:

!!! XML
!!!
%html
  %head
    %title Example
  %body
    %h1= @site.title
    - @entries.each do |entry|
      %h2= entry.title
      .body= entry.body

Individual page

public/theme/example/entry.haml:

!!! XML
!!!
%html
  %head
    %title Example
  %body
    %h1= @site.title
    %h2= @entry.title
    .body= @entry.body

How to make a plugin

Lokka Plugin is subset of Sinatra Extension. but Lokka had a specific rules of nomenclature. If you need display "Hello, World" when access to "/hello", Write a following.

public/plugin/lokka-hello/lib/lokka/hello.rb:

module Lokka::Hello
  def self.registerd(app)
    app.get '/hello' do
      'hello'
    end
  end
end

Copyright

Copyright (c) 2010 Masaki Komagata. See LICENSE for details.