grep -h "<testcase" `find . -iname "TEST-*.xml"` | sed 's/<testcase name="\(.*\)" classname="\(.*\)" time="\(.*\)".*/\3\t\2.\1/' | sort -rn | head
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Estrarre separatore string calculator | |
Pattern pattern = Pattern.compile("//(.+?)\n(.+)"); | |
Matcher matcher = pattern.matcher(input); | |
if (matcher.matches()) { | |
System.out.println(matcher.group(1)); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cowboy static files: | |
src | |
priv | |
in priv | |
static/js | |
index.html | |
index referenzia js come <script src="/static/js/controllers.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready(function() { | |
var attributes = {} | |
attributes["IT"] = 'data-amazon-it'; | |
attributes["GB"] = 'data-amazon-gb'; | |
var url = "http://freegeoip.net/json/ "; | |
jQuery.getJSON(url, function(data) { | |
var code = data.country_code; | |
var links = jQuery('[data-amazon]'); | |
jQuery.each(links, function(index, link) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo -u postgres createdb --locale it_IT.utf8 --encoding UTF8 --template template0 mopapp | |
postgres -D /opt/boxen/homebrew/var/postgres |
Goal of this Document / Gist is to layout the resources and challenges to writing a complete modern web app with Phoenix and Elixir as the state of the projects are starting on June 2015
- [Why Phoenix and not Rails or Node.js?](#Why Phoenix and not Rails or Node.js?)
- Main Resources
- Common Application Requirements
- Authentication
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Run tests: | |
mix test | |
Run single test file: | |
mix test path/to/file | |
Run single test: |
A checklist for designing and developing internet scale services, inspired by James Hamilton's 2007 paper "On Desgining and Deploying Internet-Scale Services."
- Does the design expect failures to happen regularly and handle them gracefully?
- Have we kept things as simple as possible?
- TDD by its own CANNOT leads to good design, obviously
- TDD as a mechanism to help us to learn more about good design
- Software is "Soft" just because it can be changed, it is not meant to be settled in the stone
- Test-first programming can help the team to reduce defects but it will not lead to good design
OlderNewer