mirror of
https://github.com/Ed94/gencpp.git
synced 2025-06-14 18:51:47 -07:00
some cleanup of unused macros in test files, preparing bootstrap and single header code + scripts
This commit is contained in:
41
scripts/bootstrap.ci.ps1
Normal file
41
scripts/bootstrap.ci.ps1
Normal file
@ -0,0 +1,41 @@
|
||||
[string] $type = $null
|
||||
[string] $test = $false
|
||||
|
||||
foreach ( $arg in $args )
|
||||
{
|
||||
if ( $arg -eq "test" )
|
||||
{
|
||||
$test = $true
|
||||
}
|
||||
else
|
||||
{
|
||||
$type = $arg
|
||||
}
|
||||
}
|
||||
|
||||
$path_root = git rev-parse --show-toplevel
|
||||
$path_project = Join-Path $path_root project
|
||||
$path_project_build = Join-Path $path_bootstrap build
|
||||
|
||||
write-host "`n`nBuilding gencpp bootstrap`n"
|
||||
|
||||
if ( -not( Test-Path $path_project_build) )
|
||||
{
|
||||
# Generate build files for meta-program
|
||||
Push-Location $path_project
|
||||
$args_meson = @()
|
||||
$args_meson += "setup"
|
||||
$args_meson += $path_project_build
|
||||
|
||||
& meson $args_meson
|
||||
Pop-Location
|
||||
}
|
||||
|
||||
# Compile meta-program
|
||||
Push-Location $path_root
|
||||
$args_ninja = @()
|
||||
$args_ninja += "-C"
|
||||
$args_ninja += $path_project_build
|
||||
|
||||
& ninja $args_ninja
|
||||
Pop-Location
|
2
scripts/bootstrap.ps1
Normal file
2
scripts/bootstrap.ps1
Normal file
@ -0,0 +1,2 @@
|
||||
cls
|
||||
Invoke-Expression "& $(Join-Path $PSScriptRoot 'bootstrap.ci.ps1') $args"
|
41
scripts/singleheader.ci.ps1
Normal file
41
scripts/singleheader.ci.ps1
Normal file
@ -0,0 +1,41 @@
|
||||
[string] $type = $null
|
||||
[string] $test = $false
|
||||
|
||||
foreach ( $arg in $args )
|
||||
{
|
||||
if ( $arg -eq "test" )
|
||||
{
|
||||
$test = $true
|
||||
}
|
||||
else
|
||||
{
|
||||
$type = $arg
|
||||
}
|
||||
}
|
||||
|
||||
$path_root = git rev-parse --show-toplevel
|
||||
$path_singleheader = Join-Path $path_root singleheader
|
||||
$path_singleheader_build = Join-Path $path_singleheader build
|
||||
|
||||
write-host "`n`nBuilding gencpp bootstrap`n"
|
||||
|
||||
if ( -not( Test-Path $path_singleheader_build) )
|
||||
{
|
||||
# Generate build files for meta-program
|
||||
Push-Location $path_singleheader
|
||||
$args_meson = @()
|
||||
$args_meson += "setup"
|
||||
$args_meson += $path_singleheader_build
|
||||
|
||||
& meson $args_meson
|
||||
Pop-Location
|
||||
}
|
||||
|
||||
# Compile meta-program
|
||||
Push-Location $path_root
|
||||
$args_ninja = @()
|
||||
$args_ninja += "-C"
|
||||
$args_ninja += $path_singleheader_build
|
||||
|
||||
& ninja $args_ninja
|
||||
Pop-Location
|
2
scripts/singleheader.ps1
Normal file
2
scripts/singleheader.ps1
Normal file
@ -0,0 +1,2 @@
|
||||
cls
|
||||
Invoke-Expression "& $(Join-Path $PSScriptRoot 'singleheader.ci.ps1') $args"
|
Reference in New Issue
Block a user