| "description": "URL parsing and handling library.", | "description": "URL parsing and handling library.", | ||||
| "transform": [], | "transform": [], | ||||
| "url": "git+https://github.com/vector-of-bool/neo-url.git#0.2.1" | "url": "git+https://github.com/vector-of-bool/neo-url.git#0.2.1" | ||||
| }, | |||||
| "0.2.2": { | |||||
| "depends": [ | |||||
| "neo-fun^0.5.5" | |||||
| ], | |||||
| "description": "URL parsing and handling library.", | |||||
| "transform": [], | |||||
| "url": "git+https://github.com/vector-of-bool/neo-url.git#0.2.2" | |||||
| } | } | ||||
| }, | }, | ||||
| "nlohmann-json": { | "nlohmann-json": { |
| "transform": [], | "transform": [], | ||||
| "url": "https://github.com/vector-of-bool/neo-url.git" | "url": "https://github.com/vector-of-bool/neo-url.git" | ||||
| } | } | ||||
| }, | |||||
| "0.2.2": { | |||||
| "depends": [ | |||||
| "neo-fun^0.5.5" | |||||
| ], | |||||
| "description": "URL parsing and handling library.", | |||||
| "git": { | |||||
| "ref": "0.2.2", | |||||
| "transform": [], | |||||
| "url": "https://github.com/vector-of-bool/neo-url.git" | |||||
| } | |||||
| } | } | ||||
| }, | }, | ||||
| "nlohmann-json": { | "nlohmann-json": { |
| "neo-sqlite3@0.4.1", | "neo-sqlite3@0.4.1", | ||||
| "neo-fun~0.5.4", | "neo-fun~0.5.4", | ||||
| "neo-compress~0.1.1", | "neo-compress~0.1.1", | ||||
| "neo-url~0.2.1", | |||||
| "neo-url~0.2.2", | |||||
| "semver@0.2.2", | "semver@0.2.2", | ||||
| "pubgrub@0.2.1", | "pubgrub@0.2.1", | ||||
| "vob-json5@0.1.5", | "vob-json5@0.1.5", |
| auto content = dds::slurp_file(json_path); | auto content = dds::slurp_file(json_path); | ||||
| import_json_str(content); | import_json_str(content); | ||||
| } | } | ||||
| auto& database() noexcept { return _db; } | |||||
| auto& database() const noexcept { return _db; } | |||||
| }; | }; | ||||
| } // namespace dds | |||||
| } // namespace dds |
| ? http_session::connect_ssl(*url.host, url.port_or_default_port_or(443)) | ? http_session::connect_ssl(*url.host, url.port_or_default_port_or(443)) | ||||
| : http_session::connect(*url.host, url.port_or_default_port_or(80)); | : http_session::connect(*url.host, url.port_or_default_port_or(80)); | ||||
| sess.send_head({.method = "GET", .path = url.path_string()}); | |||||
| sess.send_head({.method = "GET", .path = url.path}); | |||||
| auto res_head = sess.recv_head(); | auto res_head = sess.recv_head(); | ||||
| if (res_head.is_error()) { | if (res_head.is_error()) { | ||||
| this->url); | this->url); | ||||
| auto tdir = dds::temporary_dir::create(); | auto tdir = dds::temporary_dir::create(); | ||||
| auto url_path = fs::path(url.path_string()); | |||||
| auto url_path = fs::path(url.path); | |||||
| auto fname = url_path.filename(); | auto fname = url_path.filename(); | ||||
| if (fname.empty()) { | if (fname.empty()) { | ||||
| fname = "dds-download.tmp"; | fname = "dds-download.tmp"; |
| github_package('neo-buffer', 'vector-of-bool/neo-buffer', | github_package('neo-buffer', 'vector-of-bool/neo-buffer', | ||||
| ['0.2.1', '0.3.0', '0.4.0', '0.4.1', '0.4.2']), | ['0.2.1', '0.3.0', '0.4.0', '0.4.1', '0.4.2']), | ||||
| github_package('neo-compress', 'vector-of-bool/neo-compress', ['0.1.0', '0.1.1']), | github_package('neo-compress', 'vector-of-bool/neo-compress', ['0.1.0', '0.1.1']), | ||||
| github_package('neo-url', 'vector-of-bool/neo-url', ['0.1.0', '0.1.1', '0.1.2', '0.2.0', '0.2.1']), | |||||
| github_package('neo-url', 'vector-of-bool/neo-url', | |||||
| ['0.1.0', '0.1.1', '0.1.2', '0.2.0', '0.2.1', '0.2.2']), | |||||
| github_package('neo-sqlite3', 'vector-of-bool/neo-sqlite3', | github_package('neo-sqlite3', 'vector-of-bool/neo-sqlite3', | ||||
| ['0.2.3', '0.3.0', '0.4.0', '0.4.1']), | ['0.2.3', '0.3.0', '0.4.0', '0.4.1']), | ||||
| github_package('neo-fun', 'vector-of-bool/neo-fun', [ | github_package('neo-fun', 'vector-of-bool/neo-fun', [ |