Project

General

Profile

« Previous | Next » 

Revision 016427dd

Added by Marc Dequènes over 13 years ago

  • ID 016427dd02ba652aba3281235e512f73f3650fb5

[evol] allow specifying a file content as value in the command line for search and modify commands (closes #149)

View differences:

lib/ldap_shadows/elements/object.rb
raise PreProcessingError, _("The field '%s' cannot be modified (read only)") % field
end
if attr_info[:binary]
unless File.exists?(val)
raise PreProcessingError, _("The field '%s' contains binary data, you must provide a filename instead of a direct value") % field
end
begin
val = File.read(val)
rescue
raise PreProcessingError, _("The file for the binary field '%s' cannot be read: ") % [field, $!]
end
elsif attr_info[:syntax] == "1.3.6.1.4.1.1466.115.121.1.12"
if attr_info[:syntax] == "1.3.6.1.4.1.1466.115.121.1.12"
if val =~ FULL_HANDLE_PATTERN
obj_hdl = $1.downcase
item_hdl = $2

Also available in: Unified diff