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
Seguindo esse guia que usa o three.js: | |
https://www.youtube.com/watch?v=Q7AOvWpIVHU&t=150s&ab_channel=Fireship | |
1. Instale com o vite | |
$ cd /var/www/html | |
$ npm init vite@latest |
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 config --global alias.co checkout && git config --global alias.br branch && git config --global alias.ci commit && git config --global alias.st status && git config --global alias.last 'log -1 HEAD' && git config --global alias.visual '!gitk' && git config --global user.name "mateus" && git config --global user.email <<<USER@EMAIL>>> | |
ou | |
$ git config --global --edit | |
[alias] | |
co = checkout | |
br = branch | |
ci = commit |
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
$ rm -rf node_modules package-lock.json | |
$ npm install | |
ou faz uma busca recursiva e remove os arquivos | |
$ find . -name "node_modules" -type d -exec rm -rf {} \; | |
$ find . -name "package-lock.json" -type f -exec rm -f {} \; | |
$ find . -name "yarn.lock" -type f -exec rm -f {} \; | |
$ find . -name "yarn-error.log" -type f -exec rm -f {} \; | |
$ find . -name "yarn-debug.log" -type f -exec rm -f {} \; |
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 um compartilhamento no Debian para usar com o samba do Windows: | |
$ sudo apt update | |
$ sudo apt install cifs-utils | |
$ mkdir ~/Jarvis | |
Pegue o ip correto e o diretorio: | |
$ sudo mount.cifs //192.168.15.1/debian-share ~/Jarvis/ -o user=mateus |
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
$ cd wp-site | |
$ sudo chown -R www-data:data-data ./ | |
$ sudo find . -type d -exec chmod 755 {} \; | |
$ sudo find . -type f -exec chmod 644 {} \; |
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
Instalar o samba: | |
$ sudo apt install samba | |
$ systemctl status smbd | |
Alterar a configuracao: | |
$ cd /etc/samba/ |
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
Backup de todos bancos de dados, zipados. | |
$ mysqldump -u admin -p --all-databases | zip backup_completo_$(date +\%Y-\%m-\%d).zip - | |
Para fazer o backup de todos os bancos de dados do MySQL e já compactá-los em um arquivo .zip no Linux, você pode combinar os comandos mysqldump e zip. | |
O processo é uma variação do método tradicional, mas usando um pipe (|) para enviar a saída do mysqldump diretamente para o comando de compactação. | |
Passo 1: O comando de backup e compressão | |
Você vai usar o mysqldump com a opção --all-databases para exportar todos os seus bancos de dados e, em seguida, usar o pipe (|) para enviar essa saída para o comando zip. |
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. adicione --base='./' no npm run build: | |
{ | |
"name": "purple-moon-1", | |
"private": true, | |
"version": "0.0.0", | |
"type": "module", | |
"scripts": { | |
"dev": "vite", | |
"build": "vite build --base='./'", |
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. no wp-config.php: | |
// Enable WP_DEBUG mode | |
define('WP_DEBUG', true); | |
// Enable Debug logging to the /wp-content/debug.log file | |
define('WP_DEBUG_LOG', true); | |
// Disable display of errors and warnings | |
define( 'WP_DEBUG_DISPLAY', false ); |
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
SPC | |
SPC: find file | |
, switch buffer | |
. browse files | |
: MX | |
; EX | |
< switch buffer | |
` eval | |
u universal arg | |
x pop up scratch |
OlderNewer