<commit_before>$(document).ready(function($){

	var lat = '';
	var lon = '';
	var units = 'metric';

	var location = $.ajax({
		type: 'GET',
		url: "http://ip-api.com/json",
		crossDomain: true,
		dataType: 'json',
		success: function(data){
			console.log('success', data);
		},
		error: function(e){
			console.log('Error Finding your Location', e);
		}
	});

	location.done(function(data){
		lat = data.lat;
		lon = data.lon;
		weather();
	});
	
	function weather(){

		var appKey = "<KEY>";

		var request = $.ajax({
			type: 'GET',
			url: "https://cors-anywhere.herokuapp.com/http://api.openweathermap.org/data/2.5/weather?lat="+lat+"&lon="+lon+"&appid="+appKey+"&units="+units+"",
			crossDomain: true,
			dataType: 'json',
			success: function(data){
				console.log('success', data);
			},
			error: function(e){
				console.log('Error Loading Weather', e);
			},

		});

		request.done(function(data){
			populate(data);
		});
	};	

	function populate(data){

		//$("body").css("background", "url("+images.clearSkyNight+")");
<commit_msg>Location<commit_after>$(document).ready(function($){

	getLocation();
  
	var lat = '';
	var lon = '';
	var units = 'metric';

	function getLocation() {
	    if (navigator.geolocation) {
	      navigator.geolocation.getCurrentPosition(setPosition);
	    } else { 
	      alert("Geolocation is not supported by this browser.");
	    }
	}

	function setPosition(position) {
	    lat = position.coords.latitude;
	    lon = position.coords.longitude;
	    weather();
	}
	
	function weather(){

		var appKey = "4823e0379d7d603fb2cbfdbad5c5842e";

		var request = $.ajax({
			type: 'GET',
			url: "https://cors-anywhere.herokuapp.com/http://api.openweathermap.org/data/2.5/weather?lat="+lat+"&lon="+lon+"&appid="+appKey+"&units="+units+"",
			crossDomain: true,
			dataType: 'json',
			success: function(data){
				console.log('success', data);
			},
			error: function(e){
				console.log('Error Loading Weather', e);
			},

		});

		request.done(function(data){
			populate(data);
		});
	};	

	function populate(data){

		//$("body").css("background", "url("+images.clearSkyNight+")");

{'fraction_non_alphanumeric': 0.20093896713615023, 'fraction_numerical': 0.010328638497652582, 'mean_word_length': 3.7250554323725056, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4830330', 'n_tokens_mistral': 866, 'n_tokens_neox': 742, 'n_words': 129}