Sha256: b7791871119b0572dd4d68b633b614a2995b08fd93dd5a9dbf5c02eead14761e

Contents?: true

Size: 329 Bytes

Versions: 12

Compression:

Stored size: 329 Bytes

Contents

#!/usr/bin/env ruby

# parses and prints a fatal error out of ansible-playbook output
# 
# usage:
# 
#     qb some_role . | print-error
# 

require 'json'
require 'pp'

out = STDIN.read

json = out[/FAILED\!\ \=\>\ (\{.*\})\n/, 1]

data = JSON.load json
stderr = data['module_stderr']

# pp data

puts "STDERR:\n\n"

puts stderr

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
qb-0.1.42 bin/print-error
qb-0.1.41 bin/print-error
qb-0.1.40 bin/print-error
qb-0.1.39 bin/print-error
qb-0.1.38 bin/print-error
qb-0.1.37 bin/print-error
qb-0.1.36 bin/print-error
qb-0.1.35 bin/print-error
qb-0.1.34 bin/print-error
qb-0.1.33 bin/print-error
qb-0.1.32 bin/print-error
qb-0.1.31 bin/print-error