<commit_before>use v6;

use Net::Curl::NativeCall;

unit class Net::Curl::Easy;

has $.url;

method download {

	my $curl = curl_easy_init;
	my $body = Buf.new;

	if $curl {
		curl_easy_setopt($curl, CURLOPT_URL, $.url);
		curl_easy_setopt($curl, CURLOPT_WRITEDATA, $body);
		curl_easy_setopt($curl, CURLOPT_FOLLOWLOCATION, 0);

			# Perform the request, res will get the return code
		my $res = curl_easy_perform($curl);

		# Check for errors
		if $res != CURLE_OK {
			say "Error: curl_easy_perform() failed: " ~
			curl_easy_strerror($res);
		}

		# always cleanup
		curl_easy_cleanup($curl);
	}

	return $body.decode('latin1');
}<commit_msg>Whitespace nudge. No more tabs<commit_after>use v6;

use Net::Curl::NativeCall;

unit class Net::Curl::Easy;

has $.url;

method download {

  my $curl = curl_easy_init;
  my $body = Buf.new;

  if $curl {
    curl_easy_setopt($curl, CURLOPT_URL, $.url);
    curl_easy_setopt($curl, CURLOPT_WRITEDATA, $body);
    curl_easy_setopt($curl, CURLOPT_FOLLOWLOCATION, 0);

      # Perform the request, res will get the return code
    my $res = curl_easy_perform($curl);

    # Check for errors
    if $res != CURLE_OK {
      say "Error: curl_easy_perform() failed: " ~
      curl_easy_strerror($res);
    }

    # always cleanup
    curl_easy_cleanup($curl);
  }

  return $body.decode('latin1');
}
{'fraction_non_alphanumeric': 0.13069454817027631, 'fraction_numerical': 0.004480955937266617, 'mean_word_length': 3.962962962962963, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2091682', 'n_tokens_mistral': 578, 'n_tokens_neox': 489, 'n_words': 116}