ride 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/History.txt +4 -0
- data/License.txt +20 -0
- data/Manifest.txt +49 -0
- data/PostInstall.txt +21 -0
- data/README.txt +62 -0
- data/Rakefile +4 -0
- data/app_generators/ride/USAGE +5 -0
- data/app_generators/ride/ride_generator.rb +101 -0
- data/app_generators/ride/templates/.vim/ftdetect/ruby.vim +26 -0
- data/app_generators/ride/templates/.vim/ftplugin/ruby/ruby.vim +6 -0
- data/app_generators/ride/templates/.vim/plugin/taglist.vim +4248 -0
- data/app_generators/ride/templates/.vim/syntax/eruby.vim +42 -0
- data/app_generators/ride/templates/History.txt +4 -0
- data/app_generators/ride/templates/License.txt +20 -0
- data/app_generators/ride/templates/README.txt +62 -0
- data/app_generators/ride/templates/Rakefile +4 -0
- data/app_generators/ride/templates/config/.screenrc.code.erb +15 -0
- data/app_generators/ride/templates/config/code_template.erb +14 -0
- data/app_generators/ride/templates/script/console +10 -0
- data/app_generators/ride/templates/script/ride +149 -0
- data/app_generators/ride/templates/tasks/ride.rake +6 -0
- data/app_generators/ride/templates/tasks/rspec.rake +21 -0
- data/bin/ride +17 -0
- data/config/hoe.rb +74 -0
- data/config/requirements.rb +15 -0
- data/lib/ride/version.rb +9 -0
- data/lib/ride.rb +6 -0
- data/script/console +10 -0
- data/script/destroy +14 -0
- data/script/generate +14 -0
- data/script/txt2html +82 -0
- data/setup.rb +1585 -0
- data/spec/generator_spec_helper.rb +136 -0
- data/spec/ride_generator_spec.rb +81 -0
- data/spec/spec.opts +1 -0
- data/spec/spec_generator_helper.rb +35 -0
- data/spec/spec_helper.rb +10 -0
- data/tasks/deployment.rake +34 -0
- data/tasks/environment.rake +7 -0
- data/tasks/ride.rake +6 -0
- data/tasks/rspec.rake +21 -0
- data/tasks/website.rake +17 -0
- data/test/test_generator_helper.rb +29 -0
- data/test/test_helper.rb +2 -0
- data/test/test_ride.rb +11 -0
- data/test/test_ride_generator.rb +43 -0
- data/website/index.html +11 -0
- data/website/index.txt +83 -0
- data/website/javascripts/rounded_corners_lite.inc.js +285 -0
- data/website/stylesheets/screen.css +138 -0
- data/website/template.html.erb +48 -0
- metadata +165 -0
data/History.txt
ADDED
data/License.txt
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2008 rubyists.com (TJ Vanderpoel, Jayson Vaughn, Trey Dempsey, Kevin Berry)
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/Manifest.txt
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
History.txt
|
2
|
+
License.txt
|
3
|
+
Manifest.txt
|
4
|
+
PostInstall.txt
|
5
|
+
README.txt
|
6
|
+
Rakefile
|
7
|
+
app_generators/ride/USAGE
|
8
|
+
app_generators/ride/ride_generator.rb
|
9
|
+
app_generators/ride/templates/.vim/ftdetect/ruby.vim
|
10
|
+
app_generators/ride/templates/.vim/ftplugin/ruby/ruby.vim
|
11
|
+
app_generators/ride/templates/.vim/plugin/taglist.vim
|
12
|
+
app_generators/ride/templates/.vim/syntax/eruby.vim
|
13
|
+
app_generators/ride/templates/History.txt
|
14
|
+
app_generators/ride/templates/License.txt
|
15
|
+
app_generators/ride/templates/README.txt
|
16
|
+
app_generators/ride/templates/Rakefile
|
17
|
+
app_generators/ride/templates/config/.screenrc.code.erb
|
18
|
+
app_generators/ride/templates/config/code_template.erb
|
19
|
+
app_generators/ride/templates/script/console
|
20
|
+
app_generators/ride/templates/script/ride
|
21
|
+
app_generators/ride/templates/tasks/ride.rake
|
22
|
+
app_generators/ride/templates/tasks/rspec.rake
|
23
|
+
bin/ride
|
24
|
+
config/hoe.rb
|
25
|
+
config/requirements.rb
|
26
|
+
lib/ride.rb
|
27
|
+
lib/ride/version.rb
|
28
|
+
script/console
|
29
|
+
script/destroy
|
30
|
+
script/generate
|
31
|
+
script/txt2html
|
32
|
+
setup.rb
|
33
|
+
spec/generator_spec_helper.rb
|
34
|
+
spec/ride_generator_spec.rb
|
35
|
+
spec/spec.opts
|
36
|
+
spec/spec_generator_helper.rb
|
37
|
+
spec/spec_helper.rb
|
38
|
+
tasks/deployment.rake
|
39
|
+
tasks/environment.rake
|
40
|
+
tasks/ride.rake
|
41
|
+
tasks/rspec.rake
|
42
|
+
tasks/website.rake
|
43
|
+
test/test_helper.rb
|
44
|
+
test/test_ride.rb
|
45
|
+
website/index.html
|
46
|
+
website/index.txt
|
47
|
+
website/javascripts/rounded_corners_lite.inc.js
|
48
|
+
website/stylesheets/screen.css
|
49
|
+
website/template.html.erb
|
data/PostInstall.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
Currently ride is only viable for rails or NewGem ruby projects, though
|
2
|
+
support for more generic projects is on the way.
|
3
|
+
|
4
|
+
USAGE:
|
5
|
+
from the root of a rails or newgem project -
|
6
|
+
$ ride .
|
7
|
+
$ ./script/ride --help
|
8
|
+
$ ./script/ride <options>
|
9
|
+
|
10
|
+
With no options you get an IDE with 9 windows open, irb on window 1 and
|
11
|
+
a root file browser on 2. The other windows suppose you're in a rails tree,
|
12
|
+
but can be changed with command line options or changes to the template
|
13
|
+
in config/.screenrc.code.erb, which you can replace or copy to make
|
14
|
+
a new screen template. The home directory in the IDE is changed to
|
15
|
+
the projects' root so cd ~ takes you to the project root on a console window.
|
16
|
+
Your actual home is available via the $REAL_HOME environment variable.
|
17
|
+
|
18
|
+
Tip: Hit F12 while editing any ruby file and the current state of the buffer
|
19
|
+
will be loaded in irb, and you'll be switched to that window
|
20
|
+
|
21
|
+
For more information on ride, see http://rubyists.com/
|
data/README.txt
ADDED
@@ -0,0 +1,62 @@
|
|
1
|
+
= ride
|
2
|
+
|
3
|
+
Documentation and support can be found at:
|
4
|
+
* http://trac.rubyists.com/trac.fcgi/ride/wiki/RIDE
|
5
|
+
|
6
|
+
== DESCRIPTION:
|
7
|
+
|
8
|
+
A Ruby-based Integrated Development Environment combining GNU screen and
|
9
|
+
VIM to create a flexible environment for working on your projects. It
|
10
|
+
also allows multiple users to work together (ala pairs-coding) or work
|
11
|
+
on different pieces of a project at the same time within the same IDE.
|
12
|
+
|
13
|
+
== FEATURES/PROBLEMS:
|
14
|
+
|
15
|
+
* Uses screen to allow logical partitioning of pieces of a project, as
|
16
|
+
well as multiple users to work together in the same space.
|
17
|
+
* Uses the powerful VIM text editor to work on source files and provide
|
18
|
+
great syntax highlighting and code shortcuts (when available.)
|
19
|
+
|
20
|
+
== SYNOPSIS:
|
21
|
+
|
22
|
+
(Getting Started)
|
23
|
+
$ ride <project root>
|
24
|
+
|
25
|
+
(Getting to work)
|
26
|
+
$ script/editor
|
27
|
+
|
28
|
+
(Seeing the options)
|
29
|
+
$ script/editor --help
|
30
|
+
|
31
|
+
== REQUIREMENTS:
|
32
|
+
|
33
|
+
* screen
|
34
|
+
* vim (depends on file navigation)
|
35
|
+
* ruby (we use some ERb to make the templates work)
|
36
|
+
|
37
|
+
== INSTALL:
|
38
|
+
|
39
|
+
* FIX (sudo gem install, anything else)
|
40
|
+
|
41
|
+
== LICENSE:
|
42
|
+
|
43
|
+
Copyright (c) 2006-8 The Rubyists.
|
44
|
+
|
45
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
46
|
+
a copy of this software and associated documentation files (the
|
47
|
+
'Software'), to deal in the Software without restriction, including
|
48
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
49
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
50
|
+
permit persons to whom the Software is furnished to do so, subject to
|
51
|
+
the following conditions:
|
52
|
+
|
53
|
+
The above copyright notice and this permission notice shall be
|
54
|
+
included in all copies or substantial portions of the Software.
|
55
|
+
|
56
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
57
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
58
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
59
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
60
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
61
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
62
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/Rakefile
ADDED
@@ -0,0 +1,101 @@
|
|
1
|
+
class RideGenerator < RubiGen::Base
|
2
|
+
|
3
|
+
DEFAULT_SHEBANG = File.join(Config::CONFIG['bindir'],
|
4
|
+
Config::CONFIG['ruby_install_name'])
|
5
|
+
|
6
|
+
default_options :author => nil, :language => "ruby", :shell => 'bash', :editor => 'vim', :console_debugger => 'script/console'
|
7
|
+
|
8
|
+
attr_reader :name, :main_lib, :shell, :editor, :template, :language, :screen_name, :console_debugger
|
9
|
+
|
10
|
+
def initialize(runtime_args, runtime_options = {})
|
11
|
+
super
|
12
|
+
usage if args.empty?
|
13
|
+
@destination_root = File.expand_path(args.shift)
|
14
|
+
@name = base_name
|
15
|
+
extract_options
|
16
|
+
if @language == 'ruby'
|
17
|
+
@main_lib ||= File.basename(@destination_root)
|
18
|
+
end
|
19
|
+
@screen_name ||= @name
|
20
|
+
end
|
21
|
+
|
22
|
+
def manifest
|
23
|
+
record do |m|
|
24
|
+
# Ensure appropriate folder(s) exists
|
25
|
+
m.directory ''
|
26
|
+
BASEDIRS.each { |path| m.directory path }
|
27
|
+
|
28
|
+
# Create stubs
|
29
|
+
# m.template "template.rb", "some_file_after_erb.rb"
|
30
|
+
# m.template_copy_each ["template.rb", "template2.rb"]
|
31
|
+
# m.file "file", "some_file_copied"
|
32
|
+
# m.file_copy_each ["path/to/file", "path/to/file2"]
|
33
|
+
|
34
|
+
m.dependency "install_rubigen_scripts", [destination_root, 'ride'],
|
35
|
+
:shebang => options[:shebang], :collision => :force
|
36
|
+
m.file_copy_each %w{Rakefile History.txt License.txt README.txt}
|
37
|
+
m.file_copy_each [%w{ftplugin ruby ruby.vim}, %w{plugin taglist.vim}, %w{syntax eruby.vim}, %w{ftdetect ruby.vim}].map { |vimfile| File.join(".vim", *vimfile) }
|
38
|
+
script_options = { :chmod => 0755, :shebang => options[:shebang] == RideGenerator::DEFAULT_SHEBANG ? nil : options[:shebang] }
|
39
|
+
m.file_copy_each %w{tasks/rspec.rake tasks/ride.rake}
|
40
|
+
m.template "config/.screenrc.code.erb", "config/.screenrc.code.erb"
|
41
|
+
m.template "config/code_template.erb", "config/code_template.erb"
|
42
|
+
m.template "script/ride", "script/ride", script_options
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
protected
|
47
|
+
def banner
|
48
|
+
<<-EOS
|
49
|
+
Creates a ...
|
50
|
+
|
51
|
+
USAGE: #{spec.name} name
|
52
|
+
EOS
|
53
|
+
end
|
54
|
+
|
55
|
+
def add_options!(opts)
|
56
|
+
opts.separator ''
|
57
|
+
opts.separator 'Options:'
|
58
|
+
# For each option below, place the default
|
59
|
+
# at the top of the file next to "default_options"
|
60
|
+
# opts.on("-a", "--author=\"Your Name\"", String,
|
61
|
+
# "Some comment about this option",
|
62
|
+
# "Default: none") { |options[:author]| }
|
63
|
+
opts.on("-l", "--language", String, "Language to develop in" "Default: ruby") { |options[:language]| }
|
64
|
+
opts.on("-t", "--template", String, "Project template" "Default: rails") { |options[:template]| options[:language] = 'ruby' if options[:template] == 'rails' }
|
65
|
+
opts.on("-e", "--editor", String, "Editor to use" "Default: vim") { |options[:editor]| }
|
66
|
+
opts.on("-s", "--shell", String, "Shell to use" "Default: bash") { |options[:shell]| }
|
67
|
+
opts.on("-n", "--name", String, "What to name the screen session" "Default: #{@name}") { |options[:screen_name]| }
|
68
|
+
opts.on("-d", "--debugger", String, "What to use for window 1, debugger", "Default: script/console") { |options[:console_debugger]| }
|
69
|
+
opts.on("-v", "--version", "Show the #{File.basename($0)} version number and quit.")
|
70
|
+
end
|
71
|
+
|
72
|
+
def extract_options
|
73
|
+
# for each option, extract it into a local variable (and create an "attr_reader :author" at the top)
|
74
|
+
# Templates can access these value via the attr_reader-generated methods, but not the
|
75
|
+
# raw instance variable value.
|
76
|
+
# @author = options[:author]
|
77
|
+
@language = options[:language]
|
78
|
+
@main_dir = options[:main_dir]
|
79
|
+
@shell = options[:shell]
|
80
|
+
@editor = options[:editor]
|
81
|
+
@console_debugger = options[:console_debugger]
|
82
|
+
end
|
83
|
+
|
84
|
+
# Installation skeleton. Intermediate directories are automatically
|
85
|
+
# created so don't sweat their absence here.
|
86
|
+
BASEDIRS = %w(
|
87
|
+
lib
|
88
|
+
log
|
89
|
+
script
|
90
|
+
config
|
91
|
+
test
|
92
|
+
tasks
|
93
|
+
tmp
|
94
|
+
.vim
|
95
|
+
.vim/syntax
|
96
|
+
.vim/plugin
|
97
|
+
.vim/ftdetect
|
98
|
+
.vim/ftplugin
|
99
|
+
.vim/ftplugin/ruby
|
100
|
+
)
|
101
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
" Vim file to detect ruby/rails file types
|
2
|
+
"
|
3
|
+
" Maintainer: Tj Vanderpoel <bougy.man@gmail.com>
|
4
|
+
" Last Change: 2008 Oct 10
|
5
|
+
|
6
|
+
" only load once
|
7
|
+
if exists("b:did_load_ruby_filetypes")
|
8
|
+
finish
|
9
|
+
endif
|
10
|
+
let b:did_load_ruby_filetypes = 1
|
11
|
+
|
12
|
+
augroup filetypedetect
|
13
|
+
|
14
|
+
" Ruby
|
15
|
+
au BufNewFile,BufRead *.rb,*.rbw,*.gem,*.gemspec,*.rjs,*.rxml setf ruby
|
16
|
+
au BufNewFile,BufRead *.rb,*.rbw,*.gem,*.gemspec,*.rjs iab def def<CR>end<UP>
|
17
|
+
|
18
|
+
" ERuby
|
19
|
+
au BufNewFile,BufRead *.rhtml,*.erb setf eruby
|
20
|
+
|
21
|
+
|
22
|
+
" Ruby Makefile
|
23
|
+
au BufNewFile,BufRead [rR]akefile* setf ruby
|
24
|
+
au BufNewFile,BufRead [rR]akefile* iab def def<CR>end<UP>
|
25
|
+
|
26
|
+
augroup END
|