Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/topfunky/merb_static
A Merb plugin that creates a static version of a website, for deployment to any webserver.
https://github.com/topfunky/merb_static
Last synced: 11 days ago
JSON representation
A Merb plugin that creates a static version of a website, for deployment to any webserver.
- Host: GitHub
- URL: https://github.com/topfunky/merb_static
- Owner: topfunky
- License: mit
- Created: 2008-11-19T19:26:16.000Z (about 16 years ago)
- Default Branch: master
- Last Pushed: 2008-12-15T17:02:18.000Z (almost 16 years ago)
- Last Synced: 2024-04-15T14:13:24.903Z (7 months ago)
- Language: Ruby
- Homepage: http://peepcode.com/system/screens/
- Size: 93.8 KB
- Stars: 10
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README
- License: LICENSE
Awesome Lists containing this project
README
merb_static
===========WARNING: EXPERIMENTAL. Some features are missing or partially implemented. This is being use on small single-page sites but hasn't yet been tested with complex sites.
A plugin for the Merb framework that generates static HTML (and other) files from a dynamic Merb application.
Provides functionality similar to static-site building tools like Webby, but you can use all the plugins, helpers, and databases available to Merb.
For example, I use Mac OS X to generate screenshots for a news-reading application, but deploy to a Linux box hosted at RailsMachine. I can use merb_static to generate the HTML locally and deploy the static files and images to the server.
http://peepcode.com/system/screens/
Usage
=====In config/dependencies.rb:
dependency "merb_static"
Add other configuration information to your Merb configuration.Merb::Plugins.config[:merb_static] = {
:urls => ["/"],
:domain => "http://peepcode.com",
:remote => {
:domain => "peepcode.com",
:username => "deploy",
:passphrase => "my ssh key passphrase",
:path => "/full/path/to/deploy/this/app/to"
}
}Generate the static site:
rake merb_static:build
Start over:rake merb_static:clean
Build and deploy to a remote server:rake merb_static:sync
You may want to run your own app's tasks first by creating a custom Rake task:
task :my_sync => [:my_build_task, "merb_static:sync"]
TODO
====* Documentation
* Configuration options
* Spidering of all urls on a site
* Recommendations for writing sites that will be archived
* Synchronization task
* Tips: Use Merb::Config[:path_prefix] to generate URLs at a path