Ruby: fix linter errors
This commit is contained in:
parent
93fc88e869
commit
fc070c01b8
5 changed files with 18 additions and 11 deletions
14
Gemfile
14
Gemfile
|
@ -1,8 +1,10 @@
|
|||
source 'https://rubygems.org'
|
||||
gem 'nanoc', '~> 4.12'
|
||||
gem 'nanoc-live', '~> 1.0'
|
||||
gem 'rainpress', '~> 1.0'
|
||||
gem 'sass'
|
||||
gem 'standardrb'
|
||||
# frozen_string_literal: true
|
||||
|
||||
source "https://rubygems.org"
|
||||
gem "nanoc", "~> 4.12"
|
||||
gem "nanoc-live", "~> 1.0"
|
||||
gem "rainpress", "~> 1.0"
|
||||
gem "sass"
|
||||
gem "standardrb"
|
||||
gem "ryo.rb"
|
||||
gem "paint"
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require "bundler/setup"
|
||||
require_relative "lib/tasks"
|
||||
include Tasks
|
||||
|
|
2
Rules
2
Rules
|
@ -50,4 +50,4 @@ compile "/images/*" do
|
|||
end
|
||||
|
||||
compile("/**/*") { write(nil) }
|
||||
layout('**/*', :erb)
|
||||
layout("**/*", :erb)
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module Cmd
|
||||
def cmd(cmd, *args, silent: false)
|
||||
print " -> #{cmd}: " unless silent
|
||||
_, result = Process.wait2 Process.spawn(
|
||||
[cmd, cmd],
|
||||
*args,
|
||||
STDERR=>File::NULL,
|
||||
STDOUT=>File::NULL
|
||||
$stderr => File::NULL,
|
||||
$stdout => File::NULL
|
||||
)
|
||||
case
|
||||
when result.success?
|
||||
if result.success?
|
||||
print Paint["OK", :green, :bold], "\n" unless silent
|
||||
else
|
||||
print Paint["ERROR", :red, :bold], "\n" unless silent
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module Tasks::Deploy
|
||||
require_relative "deploy/local"
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue