2020-09-10 13:43:15 +00:00
|
|
|
function m() {
|
|
|
|
if [[ -f .notes/Makefile ]];
|
|
|
|
then
|
|
|
|
make -f .notes/Makefile "$@"
|
|
|
|
else
|
|
|
|
make "$@"
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
2019-03-22 16:27:06 +00:00
|
|
|
function mkd() {
|
|
|
|
mkdir -p "$@" && cd "$@"
|
|
|
|
}
|
|
|
|
|
2020-07-30 00:17:38 +00:00
|
|
|
function composer() {
|
|
|
|
docker run -u $UID -it --rm \
|
|
|
|
-v $(pwd):/app \
|
|
|
|
-v ~/.composer:/root/.composer \
|
|
|
|
-v ~/.ssh:/root/.ssh \
|
|
|
|
composer \
|
|
|
|
composer $*
|
|
|
|
}
|
|
|
|
|
2020-07-23 08:45:48 +00:00
|
|
|
# Run 'phpunit' or 'pest' depending on the project.
|
|
|
|
function p () {
|
|
|
|
vendor/bin/$(phpunit-or-pest) $*;
|
|
|
|
}
|
|
|
|
function pf () {
|
|
|
|
vendor/bin/$(phpunit-or-pest) --filter $*
|
|
|
|
}
|
2021-08-03 12:48:14 +00:00
|
|
|
|
|
|
|
nv() {
|
|
|
|
if [[ $# > 0 ]];
|
|
|
|
then
|
|
|
|
nvim $@
|
|
|
|
else
|
|
|
|
nvim .
|
|
|
|
fi
|
|
|
|
}
|