Skip to content

Instantly share code, notes, and snippets.

@Tardo
Last active September 18, 2020 10:44
Show Gist options
  • Save Tardo/c250f56f0e383537cdfe8e9b6ae06b01 to your computer and use it in GitHub Desktop.
Save Tardo/c250f56f0e383537cdfe8e9b6ae06b01 to your computer and use it in GitHub Desktop.
Aliases Linux #Odoo
# <> -> Required parameter
# [] -> Optional parameter
# CUSTOM ALIASES
export PERSONAL_GIT_DIR=/media/datos_linux/git
# Go to a odoo project folder
# Usage: dcd <git_project> [odoo_module]
function dcd() {
if [[ -z $2 ]]; then
cd $PERSONAL_GIT_DIR/$1
else
cd $PERSONAL_GIT_DIR/$1/odoo/custom/src/$2
fi
}
alias dcd="dcd"
# Generate the readme's (maintainer-tools uses virtualenv)
# Usage: mtreadme <branch> <repo_name> <module_name>
function mtreadme() {
RPWD=$(pwd)
(cd $PERSONAL_GIT_DIR/maintainer-tools/ &&
source .env/bin/activate &&
python -m tools.gen_addon_readme --repo-name $2 --branch $1 --addon-dir $RPWD/$3 &&
deactivate)
}
alias mtreadme="mtreadme"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment