Skip to content

Commit

Permalink
refactor openadapt to OpenAdapt
Browse files Browse the repository at this point in the history
  • Loading branch information
Krish Patel committed Jun 2, 2023
1 parent aa6e5a3 commit 853331b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
14 changes: 7 additions & 7 deletions install/install_openadapt.ps1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# PowerShell script to pull openadapt and install
# PowerShell script to pull OpenAdapt and install

# Change these if a different version of is required
$pythonCmd = "python3.10"
Expand Down Expand Up @@ -75,16 +75,16 @@ function GetPythonCMD() {
Start-Process -FilePath $pythonInstaller -Verb runAs -ArgumentList '/quiet','/uninstall' -Wait
Remove-Item $pythonInstaller

# Stop openadapt install
# Stop OpenAdapt install
Cleanup
exit
}

function Cleanup {
$exists = Test-Path -Path "..\openadapt"
$exists = Test-Path -Path "..\OpenAdapt"
if($exists) {
Set-Location ..\
Remove-Item -LiteralPath "openadapt" -Force -Recurse
Remove-Item -LiteralPath "OpenAdapt" -Force -Recurse
}
}

Expand Down Expand Up @@ -161,9 +161,9 @@ if (!$vcredistExists) {
}
}

RunAndCheck "git clone -q https://github.com/MLDSAI/openadapt.git" "clone git repo"
RunAndCheck "git clone -q https://github.com/MLDSAI/OpenAdapt.git" "clone git repo"

Set-Location .\openadapt
Set-Location .\OpenAdapt

$python = GetPythonCMD

Expand All @@ -174,4 +174,4 @@ RunAndCheck "pip install -r requirements.txt" "pip install -r requirements.txt"
RunAndCheck "pip install -e ." "pip install -e ."
RunAndCheck "alembic upgrade head" "alembic upgrade head"
RunAndCheck "python -m spacy download en_core_web_trf" "python -m spacy download en_core_web_trf"
RunAndCheck "pytest" "run openadapt tests"
RunAndCheck "pytest" "run OpenAdapt tests"
6 changes: 3 additions & 3 deletions install/install_openadapt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ RunAndCheck() {
exit 1
fi
}
[ -d "openadapt" ] && mv openadapt openadapt-$(date +%Y-%m-%d_%H-%M-%S)
RunAndCheck "git clone https://github.com/MLDSAI/openadapt.git" "clone git repo"
[ -d "OpenAdapt" ] && mv OpenAdapt OpenAdapt-$(date +%Y-%m-%d_%H-%M-%S)
RunAndCheck "git clone https://github.com/MLDSAI/OpenAdapt.git" "clone git repo"

cd openadapt
cd OpenAdapt

RunAndCheck "python3.10 -m venv .venv" "create python virtual environment"
source .venv/bin/activate
Expand Down

0 comments on commit 853331b

Please sign in to comment.