Skip to content

Instantly share code, notes, and snippets.

Avatar

Nicholas nalmeida

View GitHub Profile
@nalmeida
nalmeida / docker-help.md
Created Nov 13, 2020 — forked from bradtraversy/docker-help.md
Docker Commands, Help & Tips
View docker-help.md

Docker Commands, Help & Tips

Show commands & management commands

$ docker

Docker version info

View Class.js
// from: https://medium.com/backticks-tildes/understanding-method-chaining-in-javascript-647a9004bd4f
class Arithmetic {
constructor() {
this.value = 0;
}
sum(...args) {
this.value = args.reduce((sum, current) => sum + current, 0);
return this;
}
@nalmeida
nalmeida / twittermute.txt
Created Jan 27, 2020 — forked from IanColdwater/twittermute.txt
Here are some terms to mute on Twitter to clean your timeline up a bit.
View twittermute.txt
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
View Increase PDF font size for Kindle
# Increase PDF font size for Kindle
1. Download k2pdfopt from https://www.willus.com/k2pdfopt
2. Change the chmod: $ chmod 755 ./k2pdfopt
3. $ ./k2pdfopt ./shape-up-to-opt.pdf -ds 1.4
(Press ENTER after entering in the CLI menu to run)
Source:
* https://www.youtube.com/watch?v=ddilW4cK08s
* Using Amazon / Kindle Editor for .docx files: https://www.amazon.com/Kindle-Create/b?ie=UTF8&node=18292298011
@nalmeida
nalmeida / machine-setup
Last active Oct 16, 2015
Setting up a new Mac
View machine-setup
# Based on @mcarneiro setup: https://gist.github.com/mcarneiro/fba0e7f68ada9cf48108#file-machine-setup
# Install the following software manually via App Atore
# - Xcode
# - Microsoft remote desktop
# - Sonicwall mobile connect (VPN)
# - Evernote
# Configuration
# ---------------
View gist:cc57495cd963f42147c7
## Browser Support
<table>
<tbody>
<tr>
<td><img src="http://ie.microsoft.com/testdrive/ieblog/2010/Sep/16_UserExperiencesEvolvingthebluee_23.png" height="40"></td>
<td><img src="http://img3.wikia.nocookie.net/__cb20120330024137/logopedia/images/d/d7/Google_Chrome_logo_2011.svg" height="40"></td>
<td><img src="http://media.idownloadblog.com/wp-content/uploads/2014/06/Safari-logo-OS-X-Yosemite.png" height="40"></td>
<td><img src="http://th09.deviantart.net/fs71/200H/f/2013/185/e/b/firefox_2013_vector_icon_by_thegoldenbox-d6bxsye.png" height="40"></td>
<td><img src="http://upload.wikimedia.org/wikipedia/commons/d/d4/Opera_browser_logo_2013.png" height="40"></td>
View multiple_ssh_setting.md

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "your_email@youremail.com"
View JS Util
var $ = (function (dollar) {
if (dollar) {
return dollar;
}
return function (selector) {
return Array.prototype.slice.call(document.querySelectorAll(selector));
};
}(window.$));
View FBML Sample
<style type="text/css">
.title {
color:red;
}
.square {
background:yellow;
border:1px solid red;
text-align:center;
}
View AS2 Self Preloader
// Frame 1
var total_bytes = _root.getBytesTotal();
var loaded_bytes = _root.getBytesLoaded();
percent = loaded_bytes/total_bytes;
if(percent >=1) gotoAndPlay("_afterLoad");
// Frame 2
You can’t perform that action at this time.