Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 8a4427063e | |||
| dbb7786844 | |||
| f67e3b01fa |
+69
-6
@@ -7,14 +7,21 @@ variables:
|
||||
NET_SHARE_Z: '\\10.74.82.201\Artifacts'
|
||||
NET_SHARE_S: '\\10.74.82.201\Scambio'
|
||||
NET_SHARE_R: '\\10.74.82.201\EgwTech'
|
||||
NET_SHARE_H: '\\10.74.82.252\team drives'
|
||||
NET_USERQ: 'steamw\egalware'
|
||||
NET_USER_SERVICES: 'steamw\services'
|
||||
MACH_VERS: '0.0.0.0'
|
||||
TEMP_PATH: 'C:\MachinesDeploy'
|
||||
MACHINES_PATH_R: 'R:\EgtData\Machines'
|
||||
DEST_MACHINES_PATH_R: 'R:\EgtData\Machines\zTestYAML'
|
||||
DEST_MACHINES_PATH_H: 'H:\Beam & Wall - Essetre\test'
|
||||
SRC_PATH: ''
|
||||
BASE_PATH: ''
|
||||
TEST_PATH: ''
|
||||
URL_VERSIONS_LOG: "https://liman.egalware.com/ELM.API/api/release/save"
|
||||
MACH_VERS_NUM: '0.0.0.0'
|
||||
CRITICAL_STRING: "#critical#"
|
||||
|
||||
|
||||
#Note compilazione LUA:
|
||||
# lua54 -o bin\$FileName -s $FileName: -o = output, -s = NON include i debug symbols
|
||||
@@ -44,6 +51,22 @@ variables:
|
||||
SLEEP 2
|
||||
net use R: /delete
|
||||
|
||||
# helper copia script verso drive condiviso
|
||||
.ReplicaStor01: &ReplicaStor01
|
||||
- |
|
||||
net use H: /delete
|
||||
SLEEP 2
|
||||
net use H: $env:NET_SHARE_H /u:$env:NET_USER_SERVICES $SRVCS_PASSWD
|
||||
echo "-----------------------"
|
||||
echo " Copia macchina su stor01"
|
||||
echo "-----------------------"
|
||||
SLEEP 2
|
||||
$destinationPath = "$env:DEST_MACHINES_PATH_H\$env:MACH_NAME" + "\"
|
||||
echo $destinationPath
|
||||
ROBOCOPY "$env:BASE_PATH" "$destinationPath\" *.zip
|
||||
SLEEP 2
|
||||
net use H: /delete
|
||||
|
||||
# helper copia script verso cartella di rete R:\ per develop
|
||||
.ReplicaR_DEV: &ReplicaR_DEV
|
||||
- |
|
||||
@@ -86,7 +109,7 @@ variables:
|
||||
echo "-----------------------"
|
||||
echo " Compilazione file *.lua 32/64bit"
|
||||
echo "-----------------------"
|
||||
$FileList = Get-ChildItem("Common-*")
|
||||
$FileList = Get-ChildItem * -Include( "*.mlpe", "*.mlse")
|
||||
ForEach ($File in $FileList) {
|
||||
$FileName = Split-Path $File -leaf
|
||||
lua54 -o $env:SRC_PATH\bin\$env:MACH_NAME\$FileName -s $FileName
|
||||
@@ -109,12 +132,22 @@ variables:
|
||||
echo "-----------------------"
|
||||
echo " Calcolo versione"
|
||||
echo "-----------------------"
|
||||
|
||||
# calcolo versione formato stringa
|
||||
$fPath = "$env:MACH_NAME.mlde";
|
||||
$vLine = Select-String -path $fPath -Pattern 'PP_VER';
|
||||
$vLine = Select-String -path $fPath -Pattern '^PP_VER';
|
||||
$comp = $vLine -split "=";
|
||||
$env:MACH_VERS = $comp[1].Replace("'","").Trim()
|
||||
# display versione
|
||||
Write-Output $env:MACH_VERS;
|
||||
# display versione formato stringa
|
||||
Write-Output $env:MACH_VERS
|
||||
|
||||
# calcolo versione formato numerico
|
||||
$fPath = "$env:MACH_NAME.mlde";
|
||||
$vLine = Select-String -path $fPath -Pattern '^PP_NVER';
|
||||
$comp = $vLine -split "=";
|
||||
$env:MACH_VERS_NUM = $comp[1].Replace("'","").Trim()
|
||||
# display versione formato numerico
|
||||
Write-Output $env:MACH_VERS_NUM
|
||||
|
||||
# helper calcolo versione se develop
|
||||
.version-fix_DEV: &version-fix_DEV
|
||||
@@ -126,7 +159,7 @@ variables:
|
||||
$commitAuthor = $commitAuthor[0].Trim()
|
||||
$env:MACH_VERS = $commitAuthor
|
||||
# display versione
|
||||
Write-Output $env:MACH_VERS;
|
||||
Write-Output $env:MACH_VERS
|
||||
|
||||
# helper creazione folders
|
||||
.folder-fix: &folder-fix
|
||||
@@ -158,6 +191,33 @@ variables:
|
||||
7zip a -tzip $Target $Source
|
||||
Write-Output "called ZIP $Source --> $Target"
|
||||
|
||||
# helper invio notifica a log versioni online (LiMan)
|
||||
.SendToVersionsLog: &SendToVersionsLog
|
||||
- |
|
||||
echo "-----------------------"
|
||||
echo " Invio versione a log online"
|
||||
echo "-----------------------"
|
||||
$tags = ""
|
||||
# se critico scrive tag
|
||||
if ( $CI_COMMIT_MESSAGE | Select-String -Pattern $env:CRITICAL_STRING) {
|
||||
$tags = "CRITICAL"
|
||||
}
|
||||
$body =
|
||||
@{
|
||||
codInst = "EgalWare"
|
||||
codApp = $env:MACH_NAME
|
||||
uplAppId = "UpdateManager"
|
||||
masterKey = $LiMan_Key
|
||||
tipo = "Machine"
|
||||
versNum = $env:MACH_VERS_NUM
|
||||
versText = $env:MACH_VERS
|
||||
releaseDate = (Get-Date).toString("yyyy-MM-ddTHH:mm:ss.fffZ")
|
||||
relTags = $tags
|
||||
}
|
||||
$jsonBody = ConvertTo-Json -InputObject $body
|
||||
echo $jsonBody
|
||||
Invoke-WebRequest -Method Post -URI $env:URL_VERSIONS_LOG -ContentType "application/json" -Body $jsonBody -UseBasicParsing
|
||||
|
||||
|
||||
# helper esecuzione test
|
||||
.RunTest: &RunTest
|
||||
@@ -186,6 +246,8 @@ LuaCompile:build:
|
||||
- *LuaCompile
|
||||
- *ZipClean
|
||||
- *ReplicaR
|
||||
- *ReplicaStor01
|
||||
- *SendToVersionsLog
|
||||
|
||||
LuaCompileDev:build:
|
||||
stage: build
|
||||
@@ -233,4 +295,5 @@ LuaCompileDev:build:
|
||||
# script:
|
||||
# - *LuaCompile
|
||||
# - *ZipClean
|
||||
# - *ReplicaR
|
||||
# - *ReplicaR
|
||||
|
||||
|
||||
+3
-1
@@ -21,11 +21,13 @@
|
||||
-- 2023/09/26 DS ver 2.5i2 Corretta emissione G114 per modifica precedente.
|
||||
-- 2024/02/19 LM ver 2.6b1 In BeamData aggiunta funzione GetBlockedAxis che sostituisce la GetChainSawBlockedAxis.
|
||||
-- 2024/02/27 LM ver 2.6b2 Tutte le chiamate a EgtGetSourceDir() sostituite con EgtGetCurrMachineDir(). Aggiunto compile.
|
||||
-- 2024/09/19 LM ver 2.6i1 Modificato YAML per comunicazione versioni a LiMan. Aggiunta PP_NVER, versione in formato numerico.
|
||||
|
||||
require( 'EmtGenerator')
|
||||
EgtEnableDebug( false)
|
||||
|
||||
PP_VER = '2.6b2'
|
||||
PP_VER = '2.6i1'
|
||||
PP_NVER = '2.6.9.1'
|
||||
|
||||
-- Parametri macchina
|
||||
NumericalControl = 'NUM' -- solo NUM
|
||||
|
||||
Reference in New Issue
Block a user