{"action":"closed","issue":{"url":"https://api.github.com/repos/asciidoctor/asciidoctorj/issues/436","repository_url":"https://api.github.com/repos/asciidoctor/asciidoctorj","labels_url":"https://api.github.com/repos/asciidoctor/asciidoctorj/issues/436/labels{/name}","comments_url":"https://api.github.com/repos/asciidoctor/asciidoctorj/issues/436/comments","events_url":"https://api.github.com/repos/asciidoctor/asciidoctorj/issues/436/events","html_url":"https://github.com/asciidoctor/asciidoctorj/issues/436","id":137084028,"number":436,"title":"Conversion option template_dirs","user":{"login":"jueadams","id":4394913,"avatar_url":"https://avatars.githubusercontent.com/u/4394913?v=3","gravatar_id":"","url":"https://api.github.com/users/jueadams","html_url":"https://github.com/jueadams","followers_url":"https://api.github.com/users/jueadams/followers","following_url":"https://api.github.com/users/jueadams/following{/other_user}","gists_url":"https://api.github.com/users/jueadams/gists{/gist_id}","starred_url":"https://api.github.com/users/jueadams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jueadams/subscriptions","organizations_url":"https://api.github.com/users/jueadams/orgs","repos_url":"https://api.github.com/users/jueadams/repos","events_url":"https://api.github.com/users/jueadams/events{/privacy}","received_events_url":"https://api.github.com/users/jueadams/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-02-28T19:13:16Z","updated_at":"2016-02-28T21:40:02Z","closed_at":"2016-02-28T21:40:02Z","body":"Hi there,\r\n\r\nI tried using the option **template_dirs** by specifying the directory as a path (string) for a slim template with no success. I got:\r\n\r\n```\r\nException in thread \"main\" org.jruby.exceptions.RaiseException: (NoMethodError) asciidoctor: FAILED: C:/axb/_docs/test_guide.adoc: Failed to parse source, undefined method `each' for \"C:\\\\axb\\\\_docs\\\\backends\\\\slim\\\\docbook45\":String\r\n\tat RUBY.load(C:/MultiPlatform/ruby/lib/ruby/gems/2.2.0/gems/asciidoctor-1.5.2/lib/asciidoctor.rb:1362)\r\n\tat RUBY.convert(C:/MultiPlatform/ruby/lib/ruby/gems/2.2.0/gems/asciidoctor-1.5.2/lib/asciidoctor.rb:1458)\r\n\tat RUBY.convert_file(C:/MultiPlatform/ruby/lib/ruby/gems/2.2.0/gems/asciidoctor-1.5.2/lib/asciidoctor.rb:1562)\r\n\tat RUBY.convertFile(<script>:68)\r\n\tat org.jruby.gen.InterfaceImpl579737299.convertFile(org/jruby/gen/InterfaceImpl579737299.gen:13)\r\n```\r\n\r\nFrom the error (undefined method `each')  it seems a list is expected rather than a directory. I've tried both:\r\n\r\n```\r\n\tif (cmd.hasOption(\"T\")) {\r\n\t\tString d = cmd.getOptionValue(\"T\");\r\n\t\tFile b = new File( d );\r\n\t\tFile[] list = b.listFiles();\r\n\t\toptions.put(\"template_dirs\", d );\r\n\t}\r\n\r\n\t// Run the conversion\r\n\tif (cmd.hasOption(\"f\")) {\r\n\tString f = cmd.getOptionValue(\"f\");\r\n\t\r\n    String html = asciidoctor.convertFile(\r\n        \tnew File( f ),\r\n            options\r\n        );\r\n    System.out.println(html);\r\n   }\r\n\r\n```\r\n\r\nIf the data is given as a list (the content of the directory/files) it fails that way:\r\n\r\n```\r\nException in thread \"main\" org.jruby.exceptions.RaiseException: (NoMethodError) asciidoctor: FAILED: C:/axb/_docs/test_guide.adoc: Failed to parse source, undefined method `nil_or_empty?' for #<Java::JavaIo::File:0x7ff19c33>\r\n\tat RUBY.load(C:/MultiPlatform/ruby/lib/ruby/gems/2.2.0/gems/asciidoctor-1.5.2/lib/asciidoctor.rb:1362)\r\n\tat RUBY.convert(C:/MultiPlatform/ruby/lib/ruby/gems/2.2.0/gems/asciidoctor-1.5.2/lib/asciidoctor.rb:1458)\r\n\tat RUBY.convert_file(C:/MultiPlatform/ruby/lib/ruby/gems/2.2.0/gems/asciidoctor-1.5.2/lib/asciidoctor.rb:1562)\r\n\tat RUBY.convertFile(<script>:68)\r\n\tat org.jruby.gen.InterfaceImpl579737299.convertFile(org/jruby/gen/InterfaceImpl579737299.gen:13)\r\n```\r\n\r\nWhat data type is the option **template_dirs**? Do I wrong or is this a bug in the current version?\r\n\r\nMany thanks for any help in advance\r\n"}}