View 1-sleep-es7.js
// ES7, async/await
function sleep(ms = 0) {
return new Promise(r => setTimeout(r, ms));
}
(async () => {
console.log('a');
await sleep(1000);
console.log('b');
})()
View git-giant-file.sh
git filter-branch --force --index-filter \
'git rm --cached --ignore-unmatch fixtures/11_user_answer.json' \
--prune-empty --tag-name-filter cat -- --all
git filter-branch -f --index-filter 'git rm --cached --ignore-unmatch fixtures/11_user_answer.json'
git commit --amend -CHEAD
git push
View firebird-select-into-outfile.sql
out c:\firelog.txt;
select * from country;
out;
View update-Ubuntu-home-2018-02-16.txt
Calculando atualização... Pronto
Os NOVOS pacotes a seguir serão instalados:
libgnome-games-support-1-3
Os pacotes a seguir serão mantidos em suas versões atuais:
gir1.2-mutter-1 gnome-session-bin gnome-session-common libegl1-mesa libgbm1
libgl1-mesa-dri libgl1-mesa-glx libglapi-mesa libgles2-mesa libmutter-1-0
libosmesa6 libwayland-egl1-mesa ubuntu-session
virtualbox-guest-additions-iso
Os pacotes a seguir serão atualizados:
apt apt-utils baobab console-setup console-setup-linux dconf-cli
View update-list-work-2018-02-19.txt
O seguinte pacote foi instalado automaticamente e já não é necessário:
libgweather-3-6
Utilize 'sudo apt autoremove' para o remover.
Os NOVOS pacotes a seguir serão instalados:
libgweather-3-15
Os pacotes a seguir serão atualizados:
adminer aspell-pt aspell-pt-br baobab chromium-browser chromium-browser-l10n chromium-chromedriver chromium-codecs-ffmpeg-extra cmake cmake-data
command-not-found command-not-found-data console-setup console-setup-linux crash e2fslibs e2fsprogs e2fsprogs-l10n evolution evolution-common
evolution-data-server evolution-data-server-common evolution-data-server-dev evolution-data-server-doc evolution-data-server-online-accounts
evolution-data-server-tests evolution-dev evolution-plugin-bogofilter evolution-plugin-pstimport evolution-plugins evolution-plugins-experimental
View update-2018-02-16.txt
pacotes a seguir serão mantidos em suas versões atuais:
cheese eog evince evolution-data-server evolution-data-server-common gettext gir1.2-gnomedesktop-3.0 gir1.2-gweather-3.0 gir1.2-mutter-1 gir1.2-totem-1.0 gnome-control-center gnome-control-center-data
gnome-font-viewer gnome-screensaver gnome-session-bin gnome-session-common gnome-settings-daemon gnome-settings-daemon-schemas gnome-software gnome-software-common gnome-software-plugin-snap
guile-2.0-libs libcamel-1.2-60 libegl1-mesa libevdocument3-4 libevview3-3 libgbm1 libgl1-mesa-dri libgl1-mesa-glx libglapi-mesa libgles2-mesa libgnutls-dane0 libgnutls-openssl27 libgnutls28-dev
libgnutls30 libgnutlsxx28 libidn2-0 libidn2-dev libmutter-1-0 libnautilus-extension1a libosmesa6 libpsl5 libreoffice-avmedia-backend-gstreamer libreoffice-base-core libreoffice-calc libreoffice-common
libreoffice-core libreoffice-draw libreoffice-gnome libreoffice-gtk3 libreoffice-impress libreoffice-math libreoffice-ogltrans libreoffice-pdfimport libreoffice-style-bree
View homeenvironment-linux.txt
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu Bionic Beaver (development branch)"
----
Linux wellington-desktop 4.15.0-9-generic #10-Ubuntu SMP Thu Feb 8 20:22:38 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
---
View xz-compress-example.sh
xz -9 -vtfz production.log.old
View update-ubuntu-home-2018-02-13.txt
Os seguintes pacotes foram instalados automaticamente e já não são necessários:
libgsoap-2.8.49 libpcre2-16-0
Utilize 'sudo apt autoremove' para os remover.
Os NOVOS pacotes a seguir serão instalados:
gcc-8-base gcc-8-base:i386 libqt5texttospeech5 libteamdctl0 linux-headers-4.15.0-9 linux-headers-4.15.0-9-generic
linux-image-4.15.0-9-generic linux-image-extra-4.15.0-9-generic linux-signed-image-4.15.0-9-generic php7.2-cli php7.2-common php7.2-json
php7.2-opcache php7.2-phpdbg php7.2-readline
Os pacotes a seguir serão mantidos em suas versões atuais:
e2fslibs e2fsprogs fwupd libcomerr2 libreoffice-help-en-us libreoffice-help-pt libreoffice-help-pt-br libreoffice-l10n-pt
libreoffice-l10n-pt-br libss2 openssh-client openssh-server openssh-sftp-server ssh
View Ruby_Rails_Naming_Conventions.md

Alex's Rails Cheat Sheet

I think the most confusing thing that I have found about Ruby on Rails so far has been the transition from (trying to) write code myself to the use of the fabled "Rails Magic". So, to help my own understanding of a few core Ruby on Rails concepts, I have decided to write something on what I think is a CRITICAL topic... the idea of Convention over Configuration and why (in my mind) it is the most important thing that helps Rails become magic!

(This may be a topic that we cover in more detail in class but as I said, I'm writing this for my own understanding... I hope it helps someone else understand things too... Perhaps you can give me a hand when I'm crying next week!)

##Convention over configuration ###What does this "actually" mean...