This file contains hidden or 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
| console.clear(); | |
| const fieldsQuery = (fields) => fields | |
| .map(field => field | |
| .split(' as ') | |
| .map(each => each.trim()) | |
| .join(' as ') | |
| ).join(', '); | |
This file contains hidden or 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
| { | |
| "transations": [ | |
| { | |
| "id": 1, | |
| "value": 50, | |
| "type": ["in", "out"], | |
| "accountId": 1, | |
| "userId": 1, | |
| "isTransfer": [false, true], | |
| "isPaid": [false, true], |
This file contains hidden or 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
| export function pilha({ data, cursor, promise, results }) { | |
| return new Promise((resolve, reject) => { | |
| cursor = typeof cursor !== 'undefined' ? cursor : 0 | |
| results = typeof results !== 'undefined' ? results : [] | |
| promise(data[cursor]).then((result) => { | |
| cursor += 1 | |
| results.push(result) |
This file contains hidden or 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
| [user] | |
| name = David Costa | |
| # email = david@m3mediadigital.com.br | |
| email = davidcostadev@gmail.com | |
| [core] | |
| excludesfile = /Users/david/.gitignore_global | |
| [difftool "sourcetree"] | |
| cmd = "git mergetool -t meld " | |
| path = | |
| [mergetool "sourcetree"] |
This file contains hidden or 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
| // https://eslint.org/docs/user-guide/configuring | |
| module.exports = { | |
| root: true, | |
| parser: 'babel-eslint', | |
| parserOptions: { | |
| sourceType: 'module' | |
| }, | |
| env: { | |
| browser: true, |
This file contains hidden or 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
| function calcular() { | |
| return new Promise((resolve, reject) => { | |
| console.log('inicio...') | |
| resolve() | |
| }) | |
| } | |
| function um() { |
This file contains hidden or 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 /Applications/Install\ macOS\ Sierra.app/Contents/Resources/createinstallmedia \ | |
| --volume /Volumes/MyVolume \ | |
| --applicationpath /Applications/Install\ macOS\ Sierra.app |
This file contains hidden or 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 apt-get install -y php-pear php5-dev | |
| sudo pecl install mongo | |
| sudo sh -c "echo 'extension=mongo.so' > /etc/php/7.0/mods-available/mongo.ini" | |
| sudo ln -s /etc/php/7.0/mods-available/mongo.ini /etc/php/7.0/apache2/conf.d/mongo.ini | |
| sudo service apache2 restart |
This file contains hidden or 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
| version: '2' | |
| services: | |
| mysqlserver: | |
| image: mysql | |
| ports: | |
| - "3306:3306" | |
| volumes: | |
| - ./mysql:/var/lib/mysql | |
| environment: | |
| MYSQL_ROOT_PASSWORD: 123 |
This file contains hidden or 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
| [ | |
| { "keys": ["ctrl+v"], "command": "paste_and_indent" }, | |
| { "keys": ["ctrl+shift+v"], "command": "paste" } | |
| ] |