- Criar a pasta do projeto, no caso blog e acessá-la
mkdir blog
cd !$
- Criar o DOCKERFILE
/* ******************************************************************************************* | |
* THE UPDATED VERSION IS AVAILABLE AT | |
* https://github.com/LeCoupa/awesome-cheatsheets | |
* ******************************************************************************************* */ | |
// 0. Synopsis. | |
// http://nodejs.org/api/synopsis.html | |
#["LÓGICA DE PROGRAMAÇÃO" É BOBAGEM, e explicarei porquê.]
Se preparem que o texto é longo.
Várias vezes chegam novatos aqui perguntando como começar, e a galera diz "estuda lógica primeiro, depois vai pra linguagem X". Vivo dizendo que é bobagem. Ontem, em particular, falei isso, e vieram várias pessoas por inbox me perguntar porquê (e uma pra me xingar, achando que falei por arrogância).
Pra facilitar, eu vou escrever uma boa explicação de porquê "lógica de programação" é furada, doa a quem doer, e postar na APDA e no fórum da EnergyLabs (para futuras referências, porque esse assunto vai voltar, ctz).
(() => { | |
let count = 0; | |
function getAllButtons() { | |
return document.querySelectorAll('button.is-following') || []; | |
} | |
async function unfollowAll() { | |
const buttons = getAllButtons(); |
;; this location is "~/.pudb-bp" in older versions of pudb | |
(setq pudb-bp-file (expand-file-name "~/.config/pudb/saved-breakpoints")) | |
(defun pudb-add-breakpoint () | |
(interactive) | |
(append-to-file | |
(concat "b " buffer-file-name ":" | |
(nth 1 (split-string (what-line))) "\n") | |
nil pudb-bp-file)) | |
(define-key py-mode-map (kbd "C-c C-t") 'pudb-add-breakpoint) |
#! /usr/bin/python3 | |
HEIGHT = 15 | |
LENGTH = 30 | |
CSI = '\x1b[38;5;' | |
n = 0 | |
for i in range(HEIGHT): | |
// not iterable | |
{ | |
const myItem = { | |
a: 1, | |
b: 2 | |
} | |
// const r = [...myItem] // TypeError: myItem is not iterable | |
} | |
// now object is iterable |
#! /usr/bin/python3 | |
import sqlite3 | |
import os | |
import subprocess | |
import sys | |
from datetime import datetime | |
if len(sys.argv) > 1: | |
conn = sqlite3.connect(f'/tmp/{sys.argv[1]}.sqlite') |