Sha256: 4517178be735c5e4daedc5b196c473c26af5d2e1e1ce5a92f2e253ce41e73ba4

Contents?: true

Size: 361 Bytes

Versions: 36

Compression:

Stored size: 361 Bytes

Contents

#!/usr/bin/env ruby
# frozen_string_literal: true

$LOAD_PATH.unshift 'lib'

require 'sdr_client'

output = JSON.parse($stdin.read).tap do |hash|
  hash.dig('description', 'event').each do |event|
    event['date'].each do |event_date|
      event_date.delete('encoding') if event_date.dig('encoding', 'code') == 'w3cdtf'
    end
  end
end.to_json

puts output

Version data entries

36 entries across 36 versions & 1 rubygems

Version Path
sdr-client-2.3.1 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-2.3.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-2.2.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-2.1.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-2.0.1 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-2.0.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-1.0.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.97.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.96.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.95.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.94.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.93.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.92.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.91.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.90.0 exe/remove_w3cdtf_encoding_from_event_dates
sdr-client-0.89.0 exe/remove_w3cdtf_encoding_from_event_dates