szajbus (owner)

Fork Of

gist: 221805 by anonymous

Revisions

gist: 221916 Download_button fork
public
Public Clone URL: git://gist.github.com/221916.git
Embed All Files: show embed
Text only #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# SUPER DARING APP TEMPLATE 1.0
# By Peter Cooper, modified by Bartosz Pietrzak, MichaƂ Szajbe
 
# Delete unnecessary files
  run "rm README"
  run "rm public/index.html"
  run "rm public/favicon.ico"
  run "rm public/robots.txt"
  run "rm -f public/javascripts/*"
  run "rm log/*.log"
 
# Download JQuery
  run "curl -L http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js > public/javascripts/jquery.js"
 
# Set up git repository
  git :init
  git :add => '.'
  
# Copy database.yml for distribution use
  run "cp config/database.yml config/database.yml.example"
  
# Set up .gitignore files
  run "touch tmp/.gitignore log/.gitignore vendor/.gitignore"
  run %{find . -type d -empty | grep -v "vendor" | grep -v ".git" | grep -v "tmp" | xargs -I xxx touch xxx/.gitignore}
  file '.gitignore', <<-END
.DS_Store
log/*.log
tmp/**/*
config/database.yml
db/*.sqlite3
.*.sw[op]
END
 
# Commit all work so far to the repository
  git :add => '.'
  git :commit => "-a -m 'Initial commit'"
 
# Success!
  puts "SUCCESS!"