Am 27.10.2014 07:38, schrieb Suliman:

There is small HTML parsing lib https://github.com/Bystroushaak/DHTMLParser
I am trying to understand how to use this lib with my code (just simple App for test).

  1. Do I need to create package.json and and mark code as library?
  2. How I can set that for both files from package should be passed to compiler (like dmd findlinks.d dhtmlparser.d quoteescaper.d)?

The following (untested) should be sufficient for a dub.json
("package.json" as a name will get deprecated at some point). Target
type "library" will be inferred because there is no recognized main
source file.

{
	"name": "d-html-parser",
	"sourceFiles": ["dhtmlparser.d", "quote_escaper.d"],
	"importPaths": ["."]
}

Ideally, the two source files would be moved to a "source" or "src"
folder. That would avoid possible import conflicts and would mean than
only the name needs to be put into dub.json - the rest gets inferred then.