feat(editorconfig): add editorconfig and using php-cli from container
This commit is contained in:
36
editorconfig/dot-editorconfig
Normal file
36
editorconfig/dot-editorconfig
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
# This file is for unifying the coding style for different editors and IDEs
|
||||||
|
# editorconfig.org
|
||||||
|
|
||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
end_of_line = lf
|
||||||
|
charset = utf-8
|
||||||
|
trim_trailing_whitespace = true
|
||||||
|
insert_final_newline = true
|
||||||
|
|
||||||
|
# Spaces in coffee
|
||||||
|
[**.coffee]
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 2
|
||||||
|
|
||||||
|
[**.js]
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 2
|
||||||
|
|
||||||
|
# Tabs in less
|
||||||
|
[**.less]
|
||||||
|
indent_style = tab
|
||||||
|
indent_size = 2
|
||||||
|
|
||||||
|
[**.css]
|
||||||
|
indent_style = tab
|
||||||
|
indent_size = 2
|
||||||
|
|
||||||
|
[**.php]
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 4
|
||||||
|
|
||||||
|
[**.html]
|
||||||
|
indent_style = tab
|
||||||
|
indent_size = 2
|
||||||
@@ -15,6 +15,7 @@
|
|||||||
excludesfile = /Users/rack/.gitignore_global
|
excludesfile = /Users/rack/.gitignore_global
|
||||||
fileMode = false
|
fileMode = false
|
||||||
ignorecase = false
|
ignorecase = false
|
||||||
|
editor = nvim
|
||||||
[difftool "sourcetree"]
|
[difftool "sourcetree"]
|
||||||
cmd = opendiff \"$LOCAL\" \"$REMOTE\"
|
cmd = opendiff \"$LOCAL\" \"$REMOTE\"
|
||||||
path =
|
path =
|
||||||
|
|||||||
@@ -1,10 +1,9 @@
|
|||||||
# Add HomeBrew PATH
|
|
||||||
export PATH=/opt/homebrew/bin:$PATH
|
|
||||||
|
|
||||||
# EXA
|
# EXA
|
||||||
[ -x /opt/homebrew/bin/exa ] && alias ll="exa -l -g --icons"
|
[ -x /opt/homebrew/bin/exa ] && alias ll="exa -l -g --icons"
|
||||||
|
|
||||||
# PHP
|
# PHP in container
|
||||||
export PATH="/opt/homebrew/opt/php/bin:$PATH"
|
[ -x /usr/local/bin/docker ] && alias composer="docker run --rm --interactive --tty --volume \$PWD:/app --volume \$HOME/.composer:/tmp composer:latest composer"
|
||||||
export PATH="/opt/homebrew/opt/php/sbin:$PATH"
|
[ -x /usr/local/bin/docker ] && alias php="docker run --rm --interactive --tty --volume \$PWD:/app --volume /Users:/Users composer:latest php"
|
||||||
|
[ -x /usr/local/bin/docker ] && alias php8="docker run --rm --interactive --tty --volume \$PWD:/app composer:latest php"
|
||||||
|
[ -x /usr/local/bin/docker ] && alias php7="docker run --rm --interactive --tty --volume \$PWD:/app --workdir /app php:7.4-cli php"
|
||||||
|
[ -x /usr/local/bin/docker ] && alias laravel="docker run --rm --interactive --tty --volume \$PWD:/app --volume \$HOME/.composer:/tmp composer:latest /tmp/vendor/bin/laravel"
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# If you come from bash you might have to change your $PATH.
|
# If you come from bash you might have to change your $PATH.
|
||||||
export PATH=$HOME/bin:/usr/local/bin:$PATH
|
export PATH=$HOME/bin:$PATH
|
||||||
|
|
||||||
# Path to your oh-my-zsh installation.
|
# Path to your oh-my-zsh installation.
|
||||||
export ZSH="$HOME/.oh-my-zsh"
|
export ZSH="$HOME/.oh-my-zsh"
|
||||||
@@ -82,7 +82,7 @@ ZSH_THEME="powerlevel10k/powerlevel10k"
|
|||||||
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
|
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
|
||||||
# Example format: plugins=(rails git textmate ruby lighthouse)
|
# Example format: plugins=(rails git textmate ruby lighthouse)
|
||||||
# Add wisely, as too many plugins slow down shell startup.
|
# Add wisely, as too many plugins slow down shell startup.
|
||||||
plugins=(git)
|
plugins=(git docker ripgrep tig)
|
||||||
|
|
||||||
source $ZSH/oh-my-zsh.sh
|
source $ZSH/oh-my-zsh.sh
|
||||||
|
|
||||||
@@ -91,14 +91,14 @@ source $ZSH/oh-my-zsh.sh
|
|||||||
# export MANPATH="/usr/local/man:$MANPATH"
|
# export MANPATH="/usr/local/man:$MANPATH"
|
||||||
|
|
||||||
# You may need to manually set your language environment
|
# You may need to manually set your language environment
|
||||||
# export LANG=en_US.UTF-8
|
export LANG=en_US.UTF-8
|
||||||
|
|
||||||
# Preferred editor for local and remote sessions
|
# Preferred editor for local and remote sessions
|
||||||
# if [[ -n $SSH_CONNECTION ]]; then
|
if [[ -n $SSH_CONNECTION ]]; then
|
||||||
# export EDITOR='vim'
|
export EDITOR='vim'
|
||||||
# else
|
else
|
||||||
# export EDITOR='mvim'
|
export EDITOR='nvim'
|
||||||
# fi
|
fi
|
||||||
|
|
||||||
# Compilation flags
|
# Compilation flags
|
||||||
# export ARCHFLAGS="-arch x86_64"
|
# export ARCHFLAGS="-arch x86_64"
|
||||||
|
|||||||
Reference in New Issue
Block a user