mirror of
https://github.com/reactos/RosBE.git
synced 2025-03-02 16:25:29 +00:00
Added rosapps and rostests support to ssvn. Request by JaixBly
svn path=/trunk/tools/RosBE/; revision=1102
This commit is contained in:
parent
474116852d
commit
70f76fae22
@ -190,11 +190,13 @@ if ("$args" -eq "") {
|
||||
" Creates, updates or cleans up your ReactOS source tree or shows the revision"
|
||||
" number of the local and online trees."
|
||||
""
|
||||
" update - Updates to HEAD revision or to a specific one when the second"
|
||||
" parameter specifies one."
|
||||
" create - Creates a new ReactOS source tree."
|
||||
" cleanup - Cleans up and fixes errors in the source tree."
|
||||
" status - Show the current local and online revision numbers."
|
||||
" update - Updates to HEAD revision or to a specific one when the second"
|
||||
" parameter specifies one."
|
||||
" create - Creates a new ReactOS source tree."
|
||||
" rosapps - Creates a new ReactOS RosApps source tree."
|
||||
" rostests - Creates a new ReactOS RosTests source tree."
|
||||
" cleanup - Cleans up and fixes errors in the source tree."
|
||||
" status - Show the current local and online revision numbers."
|
||||
}
|
||||
} elseif ("$args" -eq "options") {
|
||||
if (Test-Path "$_ROSBE_BASEDIR\options.ps1") {
|
||||
|
@ -29,8 +29,28 @@ function UP($arg) {
|
||||
if ("$($arg[1])" -ne "") {
|
||||
$temparg = $arg[1]
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' update -r $temparg"
|
||||
if (Test-Path "modules\rosapps\.") {
|
||||
Set-Location modules\rosapps
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' update -r $temparg"
|
||||
Set-Location "$_ROSBE_ROSSOURCEDIR"
|
||||
}
|
||||
if (Test-Path "modules\rostests\.") {
|
||||
Set-Location modules\rostests
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' update -r $temparg"
|
||||
Set-Location "$_ROSBE_ROSSOURCEDIR"
|
||||
}
|
||||
} else {
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' update"
|
||||
if (Test-Path "modules\rosapps\.") {
|
||||
Set-Location modules\rosapps
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' update"
|
||||
Set-Location "$_ROSBE_ROSSOURCEDIR"
|
||||
}
|
||||
if (Test-Path "modules\rostests\.") {
|
||||
Set-Location modules\rostests
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' update"
|
||||
Set-Location "$_ROSBE_ROSSOURCEDIR"
|
||||
}
|
||||
}
|
||||
"Do you want to see the changelog?"
|
||||
$CL = Read-Host "Please enter 'yes' or 'no': "
|
||||
@ -81,6 +101,46 @@ elseif ("$($args[0])" -eq "create") {
|
||||
}
|
||||
}
|
||||
|
||||
# Check if the folder is empty. If not, output an error.
|
||||
elseif ("$($args[0])" -eq "rosapps") {
|
||||
$host.ui.RawUI.WindowTitle = "SVN RosApps Creating..."
|
||||
if (Test-Path "modules\rosapps\.svn\.") {
|
||||
"ERROR: Folder already contains a RosApps repository."
|
||||
} else {
|
||||
if (!(Test-Path "modules\rosapps\.")) {
|
||||
new-item -path "$_ROSBE_ROSSOURCEDIR\modules" -name rosapps -type directory
|
||||
}
|
||||
Set-Location modules\rosapps
|
||||
$dir = get-childitem
|
||||
if ("$dir" -eq "") {
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' checkout svn://svn.reactos.org/reactos/trunk/rosapps ."
|
||||
} else {
|
||||
"ERROR: Folder is not empty. Continuing is dangerous and can cause errors. ABORTED"
|
||||
}
|
||||
}
|
||||
Set-Location "$_ROSBE_ROSSOURCEDIR"
|
||||
}
|
||||
|
||||
# Check if the folder is empty. If not, output an error.
|
||||
elseif ("$($args[0])" -eq "rostests") {
|
||||
$host.ui.RawUI.WindowTitle = "SVN RosTests Creating..."
|
||||
if (Test-Path "modules\rostests\.svn\.") {
|
||||
"ERROR: Folder already contains a RosTests repository."
|
||||
} else {
|
||||
if (!(Test-Path "modules\rostests\.")) {
|
||||
new-item -path "$_ROSBE_ROSSOURCEDIR\modules" -name rostests -type directory
|
||||
}
|
||||
Set-Location modules\rostests
|
||||
$dir = get-childitem
|
||||
if ("$dir" -eq "") {
|
||||
IEX "&'$_ROSBE_BASEDIR\Tools\svn.exe' checkout svn://svn.reactos.org/reactos/trunk/rostests ."
|
||||
} else {
|
||||
"ERROR: Folder is not empty. Continuing is dangerous and can cause errors. ABORTED"
|
||||
}
|
||||
}
|
||||
Set-Location "$_ROSBE_ROSSOURCEDIR"
|
||||
}
|
||||
|
||||
# Output the revision of the local and online trees and tell the user if
|
||||
# its up to date or not.
|
||||
elseif ("$($args[0])" -eq "status") {
|
||||
|
@ -196,11 +196,13 @@ if "%1" == "" (
|
||||
echo Creates, updates or cleans up your ReactOS source tree or shows the revision
|
||||
echo number of the local and online trees.
|
||||
echo.
|
||||
echo update - Updates to HEAD revision or to a specific one when the second
|
||||
echo parameter specifies one.
|
||||
echo create - Creates a new ReactOS source tree.
|
||||
echo cleanup - Cleans up and fixes errors in the source tree.
|
||||
echo status - Show the current local and online revision numbers.
|
||||
echo update - Updates to HEAD revision or to a specific one when the second
|
||||
echo parameter specifies one.
|
||||
echo create - Creates a new ReactOS source tree.
|
||||
echo rosapps - Creates a new ReactOS RosApps source tree.
|
||||
echo rostests - Creates a new ReactOS RosTests source tree.
|
||||
echo cleanup - Cleans up and fixes errors in the source tree.
|
||||
echo status - Show the current local and online revision numbers.
|
||||
)
|
||||
) else if /i "%1" == "options" (
|
||||
if exist "%_ROSBE_BASEDIR%\options.cmd" (
|
||||
|
@ -51,7 +51,48 @@ if /i "%1" == "create" (
|
||||
) else (
|
||||
echo ERROR: Folder is not empty. Continuing is dangerous and can cause errors. ABORTED
|
||||
)
|
||||
goto :EOC
|
||||
)
|
||||
|
||||
:: Check if the folder is empty. If not, output an error.
|
||||
if /i "%1" == "rosapps" (
|
||||
title SVN RosApps Creating...
|
||||
if exist "modules\rosapps\.svn\." (
|
||||
echo ERROR: Folder already contains a RosApps repository.
|
||||
goto :EOC
|
||||
)
|
||||
if not exist "modules\rosapps\." (
|
||||
md modules\rosapps
|
||||
)
|
||||
cd modules\rosapps
|
||||
dir /b 2>nul | findstr "." >nul
|
||||
if errorlevel 1 (
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" checkout svn://svn.reactos.org/reactos/trunk/rosapps .
|
||||
) else (
|
||||
echo ERROR: Folder is not empty. Continuing is dangerous and can cause errors. ABORTED
|
||||
)
|
||||
cd "%_ROSBE_ROSSOURCEDIR%"
|
||||
goto :EOC
|
||||
)
|
||||
|
||||
:: Check if the folder is empty. If not, output an error.
|
||||
if /i "%1" == "rostests" (
|
||||
title SVN RosTests Creating...
|
||||
if exist "modules\rostests\.svn\." (
|
||||
echo ERROR: Folder already contains a RosTests repository.
|
||||
goto :EOC
|
||||
)
|
||||
if not exist "modules\rostests\." (
|
||||
md modules\rostests
|
||||
)
|
||||
cd modules\rostests
|
||||
dir /b 2>nul | findstr "." >nul
|
||||
if errorlevel 1 (
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" checkout svn://svn.reactos.org/reactos/trunk/rostests .
|
||||
) else (
|
||||
echo ERROR: Folder is not empty. Continuing is dangerous and can cause errors. ABORTED
|
||||
)
|
||||
cd "%_ROSBE_ROSSOURCEDIR%"
|
||||
goto :EOC
|
||||
)
|
||||
|
||||
@ -86,8 +127,28 @@ if not "%1" == "" (
|
||||
if "!_ROSBE_SSVN_JOB!" == "update" (
|
||||
if not "%2" == "" (
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" update -r %2
|
||||
if exist "modules\rosapps\." (
|
||||
cd modules\rosapps
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" update -r %2
|
||||
cd "%_ROSBE_ROSSOURCEDIR%"
|
||||
)
|
||||
if exist "modules\rostests\." (
|
||||
cd modules\rostests
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" update -r %2
|
||||
cd "%_ROSBE_ROSSOURCEDIR%"
|
||||
)
|
||||
) else (
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" update
|
||||
if exist "modules\rosapps\." (
|
||||
cd modules\rosapps
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" update
|
||||
cd "%_ROSBE_ROSSOURCEDIR%"
|
||||
)
|
||||
if exist "modules\rostests\." (
|
||||
cd modules\rostests
|
||||
"%_ROSBE_BASEDIR%\Tools\svn.exe" update
|
||||
cd "%_ROSBE_ROSSOURCEDIR%"
|
||||
)
|
||||
)
|
||||
)
|
||||
echo Do you want to see the changelog?
|
||||
|
Loading…
x
Reference in New Issue
Block a user