Skip to content

Instantly share code, notes, and snippets.

View rzaniboni's full-sized avatar
🏠
Working from home

Roberto Zaniboni rzaniboni

🏠
Working from home
View GitHub Profile
@rzaniboni
rzaniboni / dropDatabases.js
Created February 26, 2019 16:13
drop mongodb databases with filter
var dbs = db.getMongo().getDBNames().filter(x => x.startsWith('intro...'))
for(var i in dbs){
db = db.getMongo().getDB( dbs[i] );
print( "dropping db " + db.getName() );
db.dropDatabase();
}
@rzaniboni
rzaniboni / docker_wordpress.md
Last active January 22, 2019 08:24 — forked from bradtraversy/docker_wordpress.md
Docker Compose FIle For Wordpress, MySQL & phpmyadmin

Wordpress & Docker

This file will setup Wordpress, MySQL & PHPMyAdmin with a single command. Add the code below to a file called "docker-compose.yaml" and run the command

$ docker-compose up -d

# To Tear Down
$ docker-compose down --volumes
@rzaniboni
rzaniboni / introrx.md
Created January 9, 2019 11:28 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@rzaniboni
rzaniboni / README.md
Created November 13, 2018 14:25 — forked from elijahmanor/README.md
Export @code Extensions to a Markdown List

You can run either of the following snippets in your terminal to generate a markdown list of your VS Code extensions.

code --list-extensions | awk '{ print "* [" $1 "](https://marketplace.visualstudio.com/items\?itemName\=" $1 ")" }'

npx https://gist.github.com/elijahmanor/7f9762a4c2296839ad33e33513e88043

NOTE: You can append | pbcopy to either of the above commands to pipe the output to your Mac's copy/paste buffer.

@rzaniboni
rzaniboni / delay.js
Created October 29, 2018 14:24
delay promise javascript
const delay = ms =>
new Promise(resolve => {
setTimeout(resolve, ms);
});
@rzaniboni
rzaniboni / babel-jest.md
Last active October 26, 2018 19:17
how configure babel 7 with jest
npm i -D jest babel-jest babel-core@^7.0.0-bridge.0 @babel/core regenerator-runtime
// babel.config.js
'use strict';

module.exports = {
 presets: [