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
| #!/bin/bash | |
| # https://bbs.archlinux.org/viewtopic.php?id=134972 | |
| # How to run: ./brightness.sh -3 #(-3% of brightness) | |
| # base dir for backlight class | |
| basedir="/sys/class/backlight/" | |
| # get the backlight handler | |
| handler=$basedir$(ls $basedir)"/" |
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
| aws s3api create-bucket --bucket tasklist-node-tf-localstack --endpoint-url http://localhost:4566 | |
| aws s3api list-buckets --endpoint-url http://localhost:4566 | |
| aws s3api delete-bucket --bucket tasklist-node-tf-localstack --endpoint-url http://localhost:4566 |
Pegar as credenciais na tela inicial da AWS, Command line or programmatic access
export AWS_ACCESS_KEY_ID=""\
export AWS_SECRET_ACCESS_KEY=""\
export AWS_SESSION_TOKEN=""- aws eks --region us-east-1 update-kubeconfig --name eks-sandbox
- kubectl get svc
- Lista todos os pods: kubectl get pods
- Descreve configurações de um pod: kubectl describe pod [POD-NAME-WITH-CODE]
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
| #Criar Stream | |
| CREATE STREAM f_test_stream (message VARCHAR) WITH (kafka_topic='test', value_format='json'); | |
| #Criar o Stream que consome de outro Stream | |
| CREATE STREAM test_consumer_all_stream WITH (KAFKA_TOPIC='test1', value_format='json') AS SELECT * FROM f_test_stream; |
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
| # /!\ Double check before press enter on this command /!\ | |
| DO $$ DECLARE | |
| r RECORD; | |
| BEGIN | |
| FOR r IN (SELECT tablename FROM pg_tables WHERE schemaname = current_schema()) LOOP | |
| EXECUTE 'DROP TABLE IF EXISTS ' || quote_ident(r.tablename) || ' CASCADE'; | |
| END LOOP; | |
| END $$; |
- https://github.com/nestjs/nest
- Linha de comando: https://docs.nestjs.com/cli/overview
- Typescript por padrão
- Criação de um projeto:
nest new hello-nest
yarn install
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
| git filter-branch -f --commit-filter ' | |
| if [ "$GIT_AUTHOR_EMAIL" = "<old-email>" ]; | |
| then | |
| GIT_COMMITTER_EMAIL="<new-email>"; | |
| GIT_AUTHOR_EMAIL="<new-email>"; | |
| git commit-tree "$@"; | |
| else | |
| git commit-tree "$@"; | |
| fi' HEAD |
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
| 1. | |
| select * from city order by population desc limit 5; | |
| +------+-----------------+-------------+-------------+------------+ | |
| | ID | Name | CountryCode | District | Population | | |
| +------+-----------------+-------------+-------------+------------+ | |
| | 1024 | Mumbai (Bombay) | IND | Maharashtra | 10500000 | | |
| | 2331 | Seoul | KOR | Seoul | 9981619 | | |
| | 206 | S Paulo | BRA | S Paulo | 9968485 | | |
| +------+-----------------+-------------+-------------+------------+ |
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
| { | |
| "articles": [ | |
| { | |
| "id": 1, | |
| "title": "Quando não usar isset e empty na mesma condição" | |
| }, | |
| { | |
| "id": 2, | |
| "title": "Implementando jQuery de maneira organizada" | |
| }, |
NewerOlder