Sha256: 334eb823f93448238e3b8a278fb490c5d4b4c7637163aacba48109861c134292

Contents?: true

Size: 1.17 KB

Versions: 4

Compression:

Stored size: 1.17 KB

Contents

module Jekyll
  module Golink
    module Theme
      module Gemfile
        def create_gemfile(filename)

          # Create a Gemfile file, responsible for installing the site dependencies, that is, the gems needed to generate the site.

          File.open(filename, 'w') do |file|
            file.puts "source \"https://rubygems.org\""
            file.puts "ruby RUBY_VERSION"
            file.puts ""
            file.puts "# Dependencies"
            file.puts "gem \"rake\", \"~> 12.0\""
            file.puts "gem \"pygments.rb\", \"~> 1.1\""
            file.puts ""
            file.puts "# Loading Jekyll"
            file.puts "gem \"jekyll\", \"~> 3.4\""
            file.puts ""
            file.puts "# Plugins for #{Jekyll::Golink::Theme::NAME}"
            file.puts "group :jekyll_plugins do"
            file.puts "  gem \"jekyll-email-protect\", \"~> 1.0\""
            file.puts "end"
            file.puts ""
            file.puts "# This load the theme #{Jekyll::Golink::Theme::NAME}"
            file.puts "gem \"#{Jekyll::Golink::Theme::NAME_GEM}\", \"~> #{Jekyll::Golink::Theme::VERSION}\""
            file.puts ""
          end
        end
      end
    end
  end
end





Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
golink-1.0.3 lib/golink/template/gemfile.rb
golink-1.0.2 lib/golink/template/gemfile.rb
golink-1.0.1 lib/golink/template/gemfile.rb
golink-1.0.0 lib/golink/template/gemfile.rb