Refactoring - Ruby Edition
Extract Method
Inline Method
Inline Temp
git init . # cria um repositório | |
git remote origin https://github.com/usuario/projeto.git | |
# adiciona remote | |
# crie projeto no github antes | |
git add . # adiciona todos os arquivos | |
git commit -m 'mensagem' # faz o commit | |
git checkout -b gh-pages # cria branch gh-pages | |
git push origin gh-pages # envia para o github |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset=utf-8 /> | |
<title>Contador de Visitas</title> | |
</head> | |
<body> | |
<?php |
# Add it in your alias | |
# usage: bash-record final_gif_name speed:optional cast_file:optional | |
# | |
# Requires asciinema and docker. | |
# Optional to have gifsicle for gif optimization. | |
# | |
# Examples: | |
# bash-record testing-command-x | |
# bash-record slow-recording-x 2 | |
# bash-record please-faster-x 20 /tmp/slow-recording-x.cast |
docker run --name myadmin -d -e PMA_HOST=mydatabase.com -e PMA_USER=admin -e PMA_PASSWORD=password -p 8080:80 phpmyadmin/phpmyadmin |
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( |
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( |
/* | |
Copy this into the console of any web page that is interactive and doesn't | |
do hard reloads. You will hear your DOM changes as different pitches of | |
audio. | |
I have found this interesting for debugging, but also fun to hear web pages | |
render like UIs do in movies. | |
*/ | |
const audioCtx = new (window.AudioContext || window.webkitAudioContext)() |
* { background-color: rgba(255,0,0,.2); } | |
* * { background-color: rgba(0,255,0,.2); } | |
* * * { background-color: rgba(0,0,255,.2); } | |
* * * * { background-color: rgba(255,0,255,.2); } | |
* * * * * { background-color: rgba(0,255,255,.2); } | |
* * * * * * { background-color: rgba(255,255,0,.2); } | |
* * * * * * * { background-color: rgba(255,0,0,.2); } | |
* * * * * * * * { background-color: rgba(0,255,0,.2); } | |
* * * * * * * * * { background-color: rgba(0,0,255,.2); } |