broadway 0.0.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.
@@ -0,0 +1,32 @@
1
+ module Broadway
2
+
3
+ class StaticFile
4
+ attr_accessor :path
5
+ # Initialize a new StaticFile.
6
+ # +site+ is the Site
7
+ # +base+ is the String path to the <source>
8
+ # +dir+ is the String path between <source> and the file
9
+ # +name+ is the String filename of the file
10
+ #
11
+ # Returns <StaticFile>
12
+ def initialize(options = {})
13
+ @site = options[:site]
14
+ @path = options[:path]
15
+ @dir = @path.gsub(/#{@site.config[:source]}/, "").squeeze("/")
16
+ end
17
+
18
+ # Write the static file to the destination directory.
19
+ # +dest+ is the String path to the destination dir
20
+ #
21
+ # Returns nothing
22
+ def write(dest)
23
+ FileUtils.mkdir_p(File.join(dest, File.dirname(@dir)))
24
+ FileUtils.cp(@path, File.join(dest, @dir))
25
+ end
26
+
27
+ def inspect
28
+ "#<Broadway:StaticFile @path=#{self.path.inspect}>"
29
+ end
30
+ end
31
+
32
+ end
metadata ADDED
@@ -0,0 +1,119 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: broadway
3
+ version: !ruby/object:Gem::Version
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 0
8
+ - 1
9
+ version: 0.0.1
10
+ platform: ruby
11
+ authors:
12
+ - Lance Pollard
13
+ autorequire:
14
+ bindir: bin
15
+ cert_chain: []
16
+
17
+ date: 2010-03-22 00:00:00 -07:00
18
+ default_executable:
19
+ dependencies:
20
+ - !ruby/object:Gem::Dependency
21
+ name: nokogiri
22
+ prerelease: false
23
+ requirement: &id001 !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - ">="
26
+ - !ruby/object:Gem::Version
27
+ segments:
28
+ - 0
29
+ version: "0"
30
+ type: :runtime
31
+ version_requirements: *id001
32
+ - !ruby/object:Gem::Dependency
33
+ name: activesupport
34
+ prerelease: false
35
+ requirement: &id002 !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ segments:
40
+ - 2
41
+ - 3
42
+ - 5
43
+ version: 2.3.5
44
+ type: :runtime
45
+ version_requirements: *id002
46
+ - !ruby/object:Gem::Dependency
47
+ name: activerecord
48
+ prerelease: false
49
+ requirement: &id003 !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ segments:
54
+ - 2
55
+ - 3
56
+ - 5
57
+ version: 2.3.5
58
+ type: :runtime
59
+ version_requirements: *id003
60
+ description: "Broadway: A New Way of Googling"
61
+ email: lancejpollard@gmail.com
62
+ executables: []
63
+
64
+ extensions: []
65
+
66
+ extra_rdoc_files:
67
+ - README.textile
68
+ files:
69
+ - README.textile
70
+ - Rakefile
71
+ - lib/broadway/api.rb
72
+ - lib/broadway/asset.rb
73
+ - lib/broadway/base.rb
74
+ - lib/broadway/convertible.rb
75
+ - lib/broadway/core_ext.rb
76
+ - lib/broadway/helpers/collection_helper.rb
77
+ - lib/broadway/helpers/partial_helper.rb
78
+ - lib/broadway/helpers/text_helper.rb
79
+ - lib/broadway/helpers.rb
80
+ - lib/broadway/main.rb
81
+ - lib/broadway/page.rb
82
+ - lib/broadway/post.rb
83
+ - lib/broadway/resource.rb
84
+ - lib/broadway/runner.rb
85
+ - lib/broadway/site.rb
86
+ - lib/broadway/static_file.rb
87
+ - lib/broadway.rb
88
+ has_rdoc: true
89
+ homepage: http://github.com/viatropos/broadway
90
+ licenses: []
91
+
92
+ post_install_message:
93
+ rdoc_options: []
94
+
95
+ require_paths:
96
+ - lib
97
+ required_ruby_version: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - ">="
100
+ - !ruby/object:Gem::Version
101
+ segments:
102
+ - 0
103
+ version: "0"
104
+ required_rubygems_version: !ruby/object:Gem::Requirement
105
+ requirements:
106
+ - - ">="
107
+ - !ruby/object:Gem::Version
108
+ segments:
109
+ - 0
110
+ version: "0"
111
+ requirements: []
112
+
113
+ rubyforge_project: broadway
114
+ rubygems_version: 1.3.6
115
+ signing_key:
116
+ specification_version: 3
117
+ summary: More than Syncing Rails Apps with the Google Data API
118
+ test_files: []
119
+