From: Maxim Belkin Date: Tue, 24 Nov 2020 22:41:26 +0000 (-0600) Subject: Fix Ruby style X-Git-Url: https://git.arvados.org/rnaseq-cwl-training.git/commitdiff_plain/32ab0d162a0fb2bac0d2da2d38825ba4b19295fc Fix Ruby style --- diff --git a/Gemfile b/Gemfile index 46eedf7..41c97a9 100644 --- a/Gemfile +++ b/Gemfile @@ -2,7 +2,7 @@ source 'https://rubygems.org' -git_source(:github) {|repo_name| "https://github.com/#{repo_name}" } +git_source(:github) { |repo_name| "https://github.com/#{repo_name}" } # Synchronize with https://pages.github.com/versions ruby '>=2.7.1' diff --git a/bin/markdown_ast.rb b/bin/markdown_ast.rb index c3fd0b5..4fdb684 100755 --- a/bin/markdown_ast.rb +++ b/bin/markdown_ast.rb @@ -1,11 +1,12 @@ #!/usr/bin/env ruby +# frozen_string_literal: true # Use Kramdown parser to produce AST for Markdown document. -require "kramdown" -require "json" +require 'kramdown' +require 'json' -markdown = STDIN.read() +markdown = $stdin.read doc = Kramdown::Document.new(markdown) tree = doc.to_hash_a_s_t puts JSON.pretty_generate(tree)