diff --git a/content/books/uma-licao-de-vim/12-modelines/index.md b/content/books/uma-licao-de-vim/12-modelines/index.md index e77da35..2538645 100644 --- a/content/books/uma-licao-de-vim/12-modelines/index.md +++ b/content/books/uma-licao-de-vim/12-modelines/index.md @@ -29,7 +29,7 @@ Por exemplo, para garantir que meus templates Jinja fiquem com a sintaxe correta (usando a sintaxe de templates do Django), eu tenho colocado, como última linha do arquivo -```django +```vim {# vim: set ft=htmldjango: #} ``` @@ -42,14 +42,14 @@ Usando o exemplo acima, se eu quisesse que meus templates usassem tabulações a invés de espaços para identação mas fossem apenas 2 espaços por tabulação, eu poderia colocar, no final do arquivo: -```django +```vim {# vim: set ft=htmldjango noet ts=2 sts=2 sw=2: #} ``` O VIM ainda aceita que as opções sejam separadas em vários comandos, com a adição de ":": -```django +```vim {# vim: set ft=htmldjango:set noet:set ts=2:set sts=2:set sw=2: #} ``` diff --git a/content/code/mocking-a-mock.md b/content/code/mocking-a-mock.md index 921ca06..2ad4476 100644 --- a/content/code/mocking-a-mock.md +++ b/content/code/mocking-a-mock.md @@ -26,7 +26,7 @@ all the result records in the collection. Because it is a list (iterator, whatever), it has a `count()` function that returns the number of records. So you have something like this: -```mongodb +```javascript connector.collection.find({'field': 'value'}).count() ``` diff --git a/content/reviews/books/realm-of-racket.md b/content/reviews/books/realm-of-racket.md index a107121..41885df 100644 --- a/content/reviews/books/realm-of-racket.md +++ b/content/reviews/books/realm-of-racket.md @@ -120,18 +120,22 @@ And absolutely no example of those kinds. This is one cool thing: Racket keeps the values in their fractional format. -> ```(struct student (name id# dorm)) +> ``` +> (struct student (name id# dorm)) > (student-name freshman1) > 'Joe > (student-id# freshman1) -> 1234``` +> 1234 +> ``` Creating structs and extracting values from them. -> ```(define x 7) +> ``` +> (define x 7) > (cond [(= x 7) 5] > [(odd? x) 'odd-number] -> [else 'even-number])``` +> [else 'even-number]) +> ``` Multiple tests. Also, there is this use of brackets ("[") and parenthesis ("(") which is never properly explained, though.