Use sc::request from libscrequest
This commit is contained in:
parent
d8e726705a
commit
9df3dd7d90
@ -6,7 +6,7 @@
|
|||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
#include <libsclogging.hpp>
|
#include <libsclogging.hpp>
|
||||||
#include "requester.hpp"
|
#include <libscrequest.hpp>
|
||||||
#include "compiler.hpp"
|
#include "compiler.hpp"
|
||||||
|
|
||||||
sc::logger logger {"curly", sc::loglevel::info};
|
sc::logger logger {"curly", sc::loglevel::info};
|
||||||
@ -54,7 +54,8 @@ int main(int argc, char* argv[]) {
|
|||||||
// here when no file args
|
// here when no file args
|
||||||
std::string base_url {"https://bobpolis.com/krul/"};
|
std::string base_url {"https://bobpolis.com/krul/"};
|
||||||
std::string next_url {"start.txt"};
|
std::string next_url {"start.txt"};
|
||||||
requester req;
|
sc::requester req;
|
||||||
|
req.logger(&logger);
|
||||||
while (!done) {
|
while (!done) {
|
||||||
std::istringstream in {req.get(base_url + next_url)};
|
std::istringstream in {req.get(base_url + next_url)};
|
||||||
next_url = proc.eval(in, done);
|
next_url = proc.eval(in, done);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user