Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View JeancarloFontalvo's full-sized avatar

Jeancarlo Fontalvo (Jeancaseven) JeancarloFontalvo

View GitHub Profile
@AlejoJamC
AlejoJamC / Instalacion MongoDB Windows.md
Last active April 4, 2024 11:26
Pasos para instalar MongoDB en Windows

Instalación de MongoDB en MS Windows

  1. Obtener el instalador para Windows del centro de descargas.
  2. Iniciar el instalador como administrador.
  3. Crear las carpeta de almacenamiento y configuracion de MongoDB.
  • Dar permisos escritura y lectura a estas carpetas.
 C:\data 
 C:\data\db
@psgganesh
psgganesh / default
Last active September 13, 2022 03:24
Simple lumen nginx conf
server {
listen 80 default_server;
listen [::]:80 default_server ipv6only=on;
listen 443 ssl;
root /var/www/lumen/public;
index index.php index.html index.htm;
server_name server_domain_or_IP;
@miguelmota
miguelmota / slope-angle.js
Last active January 7, 2023 15:54
Slope angle in JavaScript
function getSlopeAngle(s1,s2) {
return Math.atan((s2[1] - s1[1]) / (s2[0] - s1[0])) * 180/Math.PI;
}
console.log(getSlopeAngle([0,0],[2,3]); // 56.309932474020215
@azadisaryev
azadisaryev / convertExcel2Sheets
Last active March 9, 2024 18:23
Google Apps Script for converting Excel (.xls or .xlsx) file to Google Spreadsheet. Drive API must be enabled in your script's Advanced Google Services and in Developers Console for the script to work (see https://developers.google.com/apps-script/guides/services/advanced#enabling_advanced_services for details).
/**
* Convert Excel file to Sheets
* @param {Blob} excelFile The Excel file blob data; Required
* @param {String} filename File name on uploading drive; Required
* @param {Array} arrParents Array of folder ids to put converted file in; Optional, will default to Drive root folder
* @return {Spreadsheet} Converted Google Spreadsheet instance
**/
function convertExcel2Sheets(excelFile, filename, arrParents) {
var parents = arrParents || []; // check if optional arrParents argument was provided, default to empty array if not
@demisx
demisx / angularjs-providers-explained.md
Last active March 17, 2024 11:09
AngularJS Providers: Constant/Value/Service/Factory/Decorator/Provider
Provider Singleton Instantiable Configurable
Constant Yes No No
Value Yes No No
Service Yes No No
Factory Yes Yes No
Decorator Yes No? No
Provider Yes Yes Yes

Constant

@kevinfjbecker
kevinfjbecker / bfs.html
Created December 27, 2011 16:16
Breadth-first Graph Traversal in JavaScript
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>A Graph</title>
<!--[if IE]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<style>
article, aside, figure, footer, header, hgroup,