Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions lib/forge/builder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,9 @@ def build_assets
end
end

# Copy the images directory over
# Copy the images & fonts directly directory over
FileUtils.cp_r(File.join(@assets_path, 'images'), @project.build_path) if File.exists?(File.join(@assets_path, 'images'))
FileUtils.cp_r(File.join(@assets_path, 'fonts'), @project.build_path) if File.exists?(File.join(@assets_path, 'fonts'))

# Check for screenshot and move it into main build directory
Dir.glob(File.join(@project.build_path, 'images', '*')).each do |filename|
Expand Down Expand Up @@ -215,7 +216,7 @@ def copy_paths_with_erb(paths, source_dir, destination_dir)
def init_sprockets
@sprockets = Sprockets::Environment.new

['javascripts', 'stylesheets', 'lib'].each do |dir|
['javascripts', 'stylesheets', 'lib', 'fonts'].each do |dir|
@sprockets.append_path File.join(@assets_path, dir)
end

Expand Down
4 changes: 4 additions & 0 deletions lib/forge/project.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ def assets_path
@assets_path ||= File.join(self.source_path, 'assets')
end

def fonts_path
File.join(self.assets_path, 'fonts')
end

def build_path
File.join(self.root, '.forge', 'build')
end
Expand Down