Skip to content

Instantly share code, notes, and snippets.

@eckelon
eckelon / show-queries-real-time
Created November 26, 2019 12:20 — forked from daniDLL/show-queries-real-time
Show executed queries in real time
## Show real-time
watch -n1 'mysql -u root -ppassword --execute="SHOW FULL PROCESSLIST"'
## Show real-time and pipe all info to file
watch -t -n1 '(mysql -u root -ppassword --execute="SHOW FULL PROCESSLIST") | tee -a mysql-process-list.log'
@eckelon
eckelon / git-clean-local-branches
Created June 19, 2019 10:12 — forked from daniDLL/git-clean-local-branches
Git clean local branches that are not on remote anymore
git branch -vv | grep -E "desaparecido|gone" | awk '{print $1}' | xargs -n1 git branch -d
@eckelon
eckelon / update_git_repos.sh
Created May 8, 2019 10:11 — forked from douglas/update_git_repos.sh
Update all git repositories under a base directory
#!/bin/bash
# store the current dir
CUR_DIR=$(pwd)
# Let the person running the script know what's going on.
printf "Checkout updated develop branch for all repos...\n\n"
# Find all git repositories and update it to the develop latest revision
for i in $(find . -name ".git" | cut -c 3-); do
@eckelon
eckelon / mage2_foler_file_permissions.md
Created March 13, 2018 09:09 — forked from evgv/mage2_foler_file_permissions.md
Magento 2 folder/file permissions

Magento 2 folder/file permissions

  • The owner of the Magento file system: Must have full control (read/write/execute) of all files and directories.
  • Must not be the web server user; it should be a different user.
  • The web server user must have write access to the following files and directories: var app/etc pub
  • In addition, the web server's group must own the Magento file system so that the Magento user (who is in the group) can share access to files with the web server user. (This includes files created by the Magento Admin or other web-based utilities.)
We recommend setting the permissions as follows:
All directories have 770 permissions.