-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4a9ad46
commit 200fc49
Showing
2 changed files
with
57 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
:: This batch script makes the Caché application deployment much faster by building and importing the project. | ||
:: Replace the variables below to match your Caché installation and build & import application to Caché using only one command. | ||
|
||
:: Caché 2016.2+ IS REQUIRED TO PROCEED | ||
@echo off | ||
|
||
:: CHANGE THIS PATH TO YOUR CACHÉ INSTALLATION PATH ON WINDOWS (folder that contains bin, CSP, mgr and other folders) | ||
set CACHE_DIR=C:\Program Files\InterSystems\Ensemble | ||
:: NAMESPACE TO IMPORT PACKAGE TO | ||
set NAMESPACE=SAMPLES | ||
:: Other variables | ||
set BUILD_DIR=build\cls | ||
set BUILD_STATIC_DIR=build\static | ||
set CSP_DIR=C:\Program Files\InterSystems\Ensemble\CSP\samples\EntityBrowser | ||
:: User credentials. Remove if necessary. | ||
set USERNAME=_SYSTEM | ||
set PASSWORD=SYS | ||
|
||
:: Build and import application to Caché | ||
echo Importing project... | ||
call npm run gulp | ||
call xcopy /sy "%~dp0\%BUILD_STATIC_DIR%" "%CSP_DIR%" | ||
( | ||
echo %USERNAME% | ||
echo %PASSWORD% | ||
echo zn "SAMPLES" set st = $system.Status.GetErrorText($system.OBJ.ImportDir("%~dp0%BUILD_DIR%",,"ck /checkuptodate=all",,1^^^)^^^) w "IMPORT STATUS: "_$case(st="",1:"OK",:st^^^), ! halt | ||
) | "%CACHE_DIR%\bin\cache.exe" -s "%CACHE_DIR%\mgr" -U %NAMESPACE% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/usr/bin/env bash | ||
# This batch script makes the Caché application deployment much faster by building and importing the project. | ||
# Replace the variables below to match your Caché installation and build & import application to Caché using only one command. | ||
|
||
# Caché 2016.2+ IS REQUIRED TO PROCEED | ||
set +v | ||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
# CHANGE THIS PATH TO YOUR CACHÉ INSTALLATION PATH (folder that contains bin, CSP, mgr and other folders) | ||
CACHE_DIR=/InterSystems/Cache | ||
# NAMESPACE TO IMPORT PACKAGE TO | ||
NAMESPACE=SAMPLES | ||
# Other variables | ||
BUILD_DIR=build/cls | ||
BUILD_STATIC_DIR=build/static | ||
CSP_DIR=/InterSystems/Cache/csp/samples/EntityBrowser | ||
# Credentials | ||
USERNAME=_SYSTEM | ||
PASSWORD=SYS | ||
|
||
# Build and import application to Caché | ||
echo "Importing project..." | ||
npm run gulp | ||
cp -R "$DIR/$BUILD_STATIC_DIR"* "$CSP_DIR" | ||
cat <<EOT | "$CACHE_DIR/bin/cache" -s "$CACHE_DIR/mgr" -U $NAMESPACE | ||
$USERNAME | ||
$PASSWORD | ||
set st = \$system.Status.GetErrorText(\$system.OBJ.ImportDir("$DIR/$BUILD_DIR",,"ck /checkuptodate=all",,1)) | ||
write "IMPORT STATUS: "_\$case(st="",1:"OK",:st), ! halt | ||
EOT |