2022-08-09 06:06:32 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# create folders
|
|
|
|
mkdir -p /workspaces/InvenTree/dev/{commandhistory,plugins}
|
|
|
|
cd /workspaces/InvenTree
|
|
|
|
|
|
|
|
# create venv
|
|
|
|
python3 -m venv dev/venv
|
|
|
|
. dev/venv/bin/activate
|
|
|
|
|
2023-05-05 12:34:42 +00:00
|
|
|
# Avoiding Dubious Ownership in Dev Containers for setup commands that use git
|
|
|
|
git config --global --add safe.directory /workspaces/InvenTree
|
|
|
|
|
2023-01-24 22:29:50 +00:00
|
|
|
# setup InvenTree server
|
2022-08-09 06:06:32 +00:00
|
|
|
pip install invoke
|
|
|
|
inv update
|
|
|
|
inv setup-dev
|
2023-05-05 12:34:42 +00:00
|
|
|
|
|
|
|
# remove existing gitconfig created by "Avoiding Dubious Ownership" step
|
2023-05-05 13:43:12 +00:00
|
|
|
# so that it gets copyied from host to the container to have your global
|
2023-05-05 12:34:42 +00:00
|
|
|
# git config in container
|
|
|
|
rm -f /home/vscode/.gitconfig
|