Skip to content

Instantly share code, notes, and snippets.

View AsharDweedar's full-sized avatar

As-har Dweedar AsharDweedar

View GitHub Profile
@anandsunderraman
anandsunderraman / arrayToCSV.js
Created September 23, 2019 20:16
Robo 3T array to csv
//function to print CSV from an array for robomongo
//place this in .robomongorc.js which should be present in your home directory
//inspired by https://github.com/Studio3T/robomongo/wiki/How-to-export-to-CSV
function toCSV(array) {
let deliminator = ',';
let textQualifier = '\"';
let headers = [];
var data = {};
var count = -1;
@LogansUA
LogansUA / robomongo_desktop_entry.md
Last active February 16, 2022 05:41
Example of desktop entry on Ubuntu system for Robomongo

Creating desktop entry

$ touch /usr/share/applications/robomongo.desktop

Edit

$ vim /usr/share/applications/robomongo.desktop
@collingo
collingo / writeJsonToFile.js
Last active February 2, 2024 13:22
Save pretty printed json to file in node
var outputLocation = require('path').resolve(__dirname, 'file.json');
require('fs').writeFile(outputLocation, JSON.stringify(data, null, 4), function(err) {
if(err) {
console.log(err);
} else {
console.log("JSON saved to "+outputLocation);
}
});