DRY, codestyle, z installation, misc

This commit is contained in:
2023-04-02 23:21:49 +03:00
parent ea292de853
commit 5e59893281
10 changed files with 121 additions and 96 deletions

17
config/alias Normal file → Executable file
View File

@@ -1,5 +1,4 @@
#!/usr/bin/env bash
# macOS specific
# Get installed php versions from brew and setup aliases
function x-set-php-aliases
@@ -42,6 +41,7 @@ if [[ $(uname) == 'Darwin' ]]; then
x-set-php-aliases
# Laravel Sail shortcut
alias sail='[ -f sail ] && bash sail || bash vendor/bin/sail'
# Flush Directory Service cache
@@ -60,15 +60,12 @@ alias zapds='find . -name ".DS_Store" -print -delete'
alias t='tail -f' # tail with follow flag on
alias dn='du -chd1' # directory usage, return only the total
alias code_scanner="docker run \
--env SOURCE_CODE='${PWD}' \
--volume '${PWD}':/code \
--volume /var/run/docker.sock:/var/run/docker.sock \
registry.gitlab.com/gitlab-org/ci-cd/codequality:${CODEQUALITY_VERSION:-latest} \
/code"
alias composerUp='composer global update'
alias npmUp='npm -g up'
alias code_scanner='docker run
--env SOURCE_CODE="$PWD"
--volume "${PWD}":/code
--volume /var/run/docker.sock:/var/run/docker.sock
registry.gitlab.com/gitlab-org/ci-cd/codequality:"${CODEQUALITY_VERSION:-latest}"
/code'
alias zedit='$EDITOR ~/.dotfiles'