Skip to content

Instantly share code, notes, and snippets.

View takahi-i's full-sized avatar

Takahiko Ito takahi-i

View GitHub Profile
@takahi-i
takahi-i / gist:54e6ce5b87fc5218018f
Last active August 29, 2015 14:15
Walter: Support Environment Variable

Load the environment variable to the Walter configuration files.

We follow the format of environment varibale as the discussion in terraform

Sample

messenger:

type: ${env.MESSENGER_TYPE}

@takahi-i
takahi-i / gist:f1a91f27044d7d0696f3
Last active August 29, 2015 14:13
Walter GitHub 連携

設定

service:
    type: github
    token: token
    from: user name
   
pipeline:
  • stage_name: command_stage_1
test do
system "#{bin}/redpen", "-version"
file_name = "sampledoc-en.txt"
path = "#{libexec}/sample-doc/en/#{file_name}"
output = `#{bin}/redpen -c #{libexec}/conf/redpen-conf-en.xml #{path}`
errors = output.split("\n").select { |line| line.start_with?(file_name) }
assert errors.find{|e|(e.start_with?("#{file_name}:1: ValidationError[SymbolWithSpace]"))}
end