mirror of
https://github.com/TTimo/GtkRadiant.git
synced 2025-01-24 18:31:36 +00:00
add git clone of Q2RePack to scons target=setup
This commit is contained in:
parent
980356d87e
commit
8354fe8f53
1 changed files with 14 additions and 0 deletions
14
config.py
14
config.py
|
@ -52,6 +52,7 @@ class Config:
|
||||||
'WolfPack',
|
'WolfPack',
|
||||||
'UnvanquishedPack',
|
'UnvanquishedPack',
|
||||||
'Q1Pack',
|
'Q1Pack',
|
||||||
|
'Q2RePack',
|
||||||
]
|
]
|
||||||
|
|
||||||
def __repr__( self ):
|
def __repr__( self ):
|
||||||
|
@ -284,9 +285,22 @@ class Config:
|
||||||
print( repr( cmd ) )
|
print( repr( cmd ) )
|
||||||
subprocess.check_call( cmd )
|
subprocess.check_call( cmd )
|
||||||
|
|
||||||
|
def GitCloneOrUpdate( self, git_url, path ):
|
||||||
|
if os.path.exists( path ):
|
||||||
|
cmd = [ 'git', 'pull' ]
|
||||||
|
print( repr( cmd ) )
|
||||||
|
subprocess.check_call( cmd, cwd = path )
|
||||||
|
else:
|
||||||
|
cmd = [ 'git', 'clone', git_url, path ]
|
||||||
|
print( repr( cmd ) )
|
||||||
|
subprocess.check_call( cmd )
|
||||||
|
|
||||||
def FetchGamePaks( self, path ):
|
def FetchGamePaks( self, path ):
|
||||||
for pak in self.setup_packs:
|
for pak in self.setup_packs:
|
||||||
pak_path = os.path.join( path, 'installs', pak )
|
pak_path = os.path.join( path, 'installs', pak )
|
||||||
|
if pak == 'Q2RePack':
|
||||||
|
self.GitCloneOrUpdate( 'https://github.com/TTimo/Q2RePack.git', pak_path )
|
||||||
|
continue
|
||||||
if pak == 'UnvanquishedPack':
|
if pak == 'UnvanquishedPack':
|
||||||
svnurl = 'https://github.com/Unvanquished/unvanquished-mapeditor-support.git/trunk/build/gtkradiant/'
|
svnurl = 'https://github.com/Unvanquished/unvanquished-mapeditor-support.git/trunk/build/gtkradiant/'
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue