Spec permanente do bounded context. Vive no repo enquanto o sistema viver. Atualize quando arquitetura ou regra de domínio mudar — não quando código mudar.
Em uma frase: o que esse contexto faz e o que não faz.
This gist details how to create or restore a disk image in Mac OSX. There are three methods that are described: Carbon Copy Cloner, Disk Utility, and CommandLine.
Updated by: Scott Borecki
[![LinkedIn: scott-borecki][linkedin-badge]][LinkedIn] [![Email: scottborecki@gmail.com][gmail-badge]][gmail] [![GitHub: Scott-Borecki][github-follow-badge]][GitHub]
Please reach out if you have any comments or suggestions for updates!
Updated by: Chris Simmons, based on the 5.2 Cheatsheet by Scott Borecki.
Please reach out if you have any comments or suggestions for updates!
rails -v to check your Rails version number.$:| // ==UserScript== | |
| // @name Unblur scribd.com | |
| // @namespace http://tampermonkey.net/ | |
| // @version 0.1 | |
| // @description try to take over the world! | |
| // @author You | |
| // @match https://vi.scribd.com/* | |
| // @grant none | |
| // ==/UserScript== | |
| (function() { |
| #!/bin/bash | |
| # herein we backup our indexes! this script should run at like 3 AM every first day of the month, after logstash | |
| # rotates to a new ES index and theres no new data coming in to the old one. we grab metadatas, | |
| # compress the data files and backs up to whatever long term storage. | |
| . ./config.sh | |
| echo "Checking that index exist in ES" | |
| if [ `curl -sI $ESURL/$INDEXNAME | grep OK | wc -l` -eq 0 ] | |
| then |
| # config to don't allow the browser to render the page inside an frame or iframe | |
| # and avoid clickjacking http://en.wikipedia.org/wiki/Clickjacking | |
| # if you need to allow [i]frames, you can use SAMEORIGIN or even set an uri with ALLOW-FROM uri | |
| # https://developer.mozilla.org/en-US/docs/HTTP/X-Frame-Options | |
| add_header X-Frame-Options SAMEORIGIN; | |
| # when serving user-supplied content, include a X-Content-Type-Options: nosniff header along with the Content-Type: header, | |
| # to disable content-type sniffing on some browsers. | |
| # https://www.owasp.org/index.php/List_of_useful_HTTP_headers | |
| # currently suppoorted in IE > 8 http://blogs.msdn.com/b/ie/archive/2008/09/02/ie8-security-part-vi-beta-2-update.aspx |
| defmodule Slug1 do | |
| def slugify(input), do: map_slug(input, %{pattern: ~r/\s+/}) | |
| def slugify2(input), do: map_slug(input, %{pattern: " "}) | |
| defp map_slug(input, %{pattern: pattern}) do | |
| input | |
| |> to_string() | |
| |> String.trim() | |
| |> String.downcase() |
| raise 'Wrong Ruby version!' unless RUBY_VERSION >= '2.6.0' | |
| module Strings | |
| Trim = -> str { String(str).strip } | |
| Replace = -> (sub, new_sub, str) { String(str).gsub(sub, new_sub) } | |
| LowerCase = -> str { String(str).downcase } | |
| end | |
| # -- Alternative syntax -- | |
| Slugify = # Slugify = |