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
Atualizar o sistema | |
sudo apt-get update && sudo apt-get -y upgrade && sudo apt-get -y dist-upgrade | |
Instalação do MysqlServer | |
sudo apt-get install mysql-server | |
Instalação do Apache2 | |
sudo apt-get install apache2 | |
Instalação do PHP7.0 |
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
Referencias | |
https://blog.pantuza.com/tutoriais/criando-um-servidor-git | |
O git é uma ferramenta de linha de comandos para fazer controle de versões de código. Existem alguns sites na web, como o Github, que utilizam o git para criar uma serviço de gestão de projetos de código. Se você tem uma empresa, ou um laboratório de universidade e precisa ter um repositório Git remote ao qual uma equipe ou diversos colaboradores precisam enviar código, esse tutorial irá te ajudar a habilitar um servidor Git remoto. | |
Caso goste de interfaces gráficas, uma alternativa seria configurar o Gitlab em sua empresa ou laboratório. Essa ferramenta é mais amigável e preparada para controlar o projeto com interações mais humanas. Esse tutorial irá habilitar apenas a interação via linha de comando utilizando o utilitário git. | |
Vamos dividir nosso tutorial em duas partes. A primeira será o nosso servidor. A segunda será o nosso cliente. Essa última se aplica a todos os usuários que desejam fazer uso do serviço. | |
SERVIDOR | |
Vamos começar |
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
public function validarCnpj($cnpj) | |
{ | |
$cnpj = preg_replace('/[^0-9]/', '', (string) $cnpj); | |
// Valida tamanho | |
if (strlen($cnpj) != 14) { | |
return false; | |
} | |
// Lista de CNPJs inválidos | |
$invalidos = [ |
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
#Configure env file | |
MAIL_DRIVER=smtp | |
MAIL_HOST=smtp.gmail.com | |
MAIL_PORT=587 | |
MAIL_USERNAME=your_email@gmail.com | |
MAIL_PASSWORD=your_password | |
MAIL_ENCRYPTION=tls | |
#Controller |
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
[ | |
{ | |
"id": [1, 2, 3], | |
"evolution_tree": [ | |
{ | |
"id": 1, | |
"name": "Bulbasaur", | |
"image": "https://pokeres.bastionbot.org/images/pokemon/1.png" | |
}, | |
{ |
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
root = true | |
[*] | |
end_of_line = lf | |
indent_style = space | |
indent_size = 2 | |
charset = utf-8 | |
trim_trailing_whitespace = true | |
insert_final_newline = true |
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
{ | |
"singleQuote": true, | |
"trailingComma": "es5" | |
} |
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
module.exports = { | |
env: { | |
browser: true, | |
es2021: true, | |
}, | |
extends: ["airbnb", "prettier", "prettier/react"], | |
globals: { | |
Atomics: "readonly", | |
SharedArrayBuffer: "readonly", | |
}, |
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
[ | |
[ | |
{ | |
"id": 1, | |
"slug": "acrelandia", | |
"city": "Acrelândia", | |
"state": "Acre", | |
"uf": "AC" | |
}, | |
{ |
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
References: | |
https://askubuntu.com/questions/730754/how-do-i-show-the-git-branch-with-colours-in-bash-prompt | |
Edit your bashrc file | |
$ nano ~/.bashrc | |
Add these lines in your ~/.bashrc file | |
... |
OlderNewer