- http://stackoverflow.com/questions/804115 (
rebase
vsmerge
). - https://www.atlassian.com/git/tutorials/merging-vs-rebasing (
rebase
vsmerge
) - https://www.atlassian.com/git/tutorials/undoing-changes/ (
reset
vscheckout
vsrevert
) - http://stackoverflow.com/questions/2221658 (HEAD^ vs HEAD~) (See
git rev-parse
) - http://stackoverflow.com/questions/292357 (
pull
vsfetch
) - http://stackoverflow.com/questions/39651 (
stash
vsbranch
) - http://stackoverflow.com/questions/8358035 (
reset
vscheckout
vsrevert
)
/* ******************************************************************************************* | |
* GLOBAL OBJECTS > ARRAY | |
* https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array | |
* ******************************************************************************************* */ | |
// Global object: properties | |
Array.length // Reflects the number of elements in an array | |
// Global object: methods |
Commands, questions and easter eggs for Amazon Alexa enabled devices: https://ugotsta.github.io/alexa-cheats/
- "Alexa, stop."
- "Alexa, volume one/six/ten."
- "Alexa, turn up/down the bass/treble."
- "Alexa, mute."
- "Alexa, unmute."
- "Alexa, repeat."
docker build -t friendlyname . # Create image using this directory's Dockerfile | |
docker run -p 4000:80 friendlyname # Run "friendlyname" mapping port 4000 to 80 | |
docker run -d -p 4000:80 friendlyname # Same thing, but in detached mode | |
docker exec -it [container-id] bash # Enter a running container | |
docker ps # See a list of all running containers | |
docker stop <hash> # Gracefully stop the specified container | |
docker ps -a # See a list of all containers, even the ones not running | |
docker kill <hash> # Force shutdown of the specified container | |
docker rm <hash> # Remove the specified container from this machine | |
docker rm $(docker ps -a -q) # Remove all containers from this machine |
IPTables is the Firewall service that is available in a lot of different Linux Distributions. While modifiying it might seem daunting at first, this Cheat Sheet should be able to show you just how easy it is to use and how quickly you can be on your way mucking around with your firewall.
The following list is a great set of documentation for iptables
. I used them to compile this documentation.
- How-To Geek: The Beginner’s Guide to iptables, the Linux Firewall: https://www.howtogeek.com/177621/the-beginners-guide-to-iptables-the-linux-firewall/
- IPTables Essentials: Common Firewall Rules and COmmands https://www.digitalocean.com/community/tutorials/iptables-essentials-common-firewall-rules-and-commands
- Hyperpolyglot: Side by side comparison of a variety of languages and programming tools.
- Git Cheatsheet, Git Tips/Tricks
- Explainshell: Type a shell command and get an explanation of what it does through showing the docs
- RegExr: A learning tool and a cheat sheet for Regex.
- Pramp: Free forever peer-to-peer technical interview practice.
- InterviewBit: Gamified practice for typical coding interview questions.
- Project Euler: Math/CS related challenge problems. Try them and complete them at your own pace.
**NOTA IMPORTANTE Questi appunti sono ormai molto datati e incompleti. Li lascio qui per ragioni storiche e affettive, ma davvero, non prendeli alla lettera e non sorprendetevi se ci sono cose sbagliate. Il mio libro Python in Windows parla di tutte queste cose, e di molto altro ancora, in modo più aggiornato, completo e corretto. Vi suggerisco almeno di scaricare il capitolo introduttivo gratuito per farvi un'idea degli argomenti trattati. **
Questi appunti descrivono come installare Python su Windows in modo da creare un ambiente di lavoro sano, facile da usare all'inizio e che possa durare nel tempo senza sfuggirvi di mano quando le cose si fanno più complicate.
Per prima cosa, chiariamo: installare Python su Windows non è per niente complicato di per sé. Potete andare sul sito, scaricare, installare in pochi secondi e cominciare subito a lavorare. All'inizio non avrete difficoltà. Quando prim
Angular (aka Angular 2) is a new framework completely rewritten from the ground up, replacing the famous AngularJS framework (aka Angular 1.x).
More that just a framework, Angular should now be considered as a whole platform which comes with a complete set of tools, like its own CLI, debug utilities or performance tools.
# Count total EBS based storage in AWS | |
aws ec2 describe-volumes | jq "[.Volumes[].Size] | add" | |
# Count total EBS storage with a tag filter | |
aws ec2 describe-volumes --filters "Name=tag:Name,Values=CloudEndure Volume qjenc" | jq "[.Volumes[].Size] | add" | |
# Describe instances concisely | |
aws ec2 describe-instances | jq '[.Reservations | .[] | .Instances | .[] | {InstanceId: .InstanceId, State: .State, SubnetId: .SubnetId, VpcId: .VpcId, Name: (.Tags[]|select(.Key=="Name")|.Value)}]' | |
# Wait until $instance_id is running and then immediately stop it again | |
aws ec2 wait instance-running --instance-id $instance_id && aws ec2 stop-instances --instance-id $instance_id | |
# Get 10th instance in the account |