Project

General

Profile

« Previous | Next » 

Revision f7217dcd

Added by Marc Dequènes over 15 years ago

  • ID f7217dcdffe4d0fc4711c30a59da1f76064cc40a

[evol] move display options out of object management into the display functions, and display binary field presence

View differences:

bin/shadowwalker
exit 2
end
$program_options[:skip_binary] = true
Display.display_item(item, $program_options)
end
cmdparser.add_command(cmd)
......
item_hdl = args.shift
begin
item = obj_klass.find(item_hdl, :attributes => ["*",])
item = obj_klass.find(item_hdl)
rescue ActiveLdap::EntryNotFound
STDERR.puts "No such item '#{obj_hdl}/#{item_hdl}'"
exit 2
......
key = $1
op = $2
val = $3
puts "key: #{key}"
puts "op: #{op}"
puts "val: #{val}"
if key.nil?
STDERR.puts "Syntax error in modification parameters: invalid field name"
......
if modification_done
puts "Modified attributes:"
p item.modified_attributes
begin
item.save!
rescue ActiveLdap::OperationNotPermitted => e
......
cmdparser.add_command(cmd)
cmdparser.parse
# ActiveLdap bugs:
# - fetching operational attributes in an object used for modification cause
# collect_modified_attributes() to catch them by mistake and triggers an
# ActiveLdap::LdapError::ConstraintViolation exception

Also available in: Unified diff