Skip to content

Commit

Permalink
Fix rubocop issues in metanorma, git_template.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
CAMOBAP committed Jul 16, 2021
1 parent 5cdaabb commit 037c87c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 4 additions & 2 deletions exe/metanorma
Expand Up @@ -11,8 +11,10 @@ $:.unshift File.expand_path("../../lib", bin_file)
# Fixes https://github.com/rubygems/rubygems/issues/1420
require "rubygems/specification"

class Gem::Specification
def this; self; end
module Gem
class Specification
def this; self; end
end
end

# start up the CLI
Expand Down
7 changes: 3 additions & 4 deletions lib/metanorma/cli/git_template.rb
Expand Up @@ -10,16 +10,15 @@ def initialize(name, options = {})

def remove!
remove_template
return true
true
end

def download
remove!
clone_git_template(options[:repo])

rescue Git::GitExecuteError
UI.say("Invalid template reoository!")
return nil
nil
end

def find_or_download
Expand Down Expand Up @@ -86,7 +85,7 @@ def git_repos
iso: "https://github.com/metanorma/mn-templates-iso",
iec: "https://github.com/metanorma/mn-templates-iec",
itu: "https://github.com/metanorma/mn-templates-itu",
ietf: "https://github.com/metanorma/mn-templates-ietf"
ietf: "https://github.com/metanorma/mn-templates-ietf",
}
end

Expand Down

0 comments on commit 037c87c

Please sign in to comment.