Please enable JavaScript to use RhodeCode Enterprise
Commit Description:
Add packaging script.
Commit Description:
Add packaging script.
#!/bin/env python3
import zipfile
import sys
import shutil
import os
import pathlib
macos_template = "isometric-park-fna/bin/isometric-park-template.app"
windows_template = "isometric-park-fna/bin/isometric-park-windows-template"
def make_windows ( suffix = "new" ):
pass
def make_macos ( suffix = "new" ):
new_name = macos_template [: - 4 ] + "-" + suffix + ".app" + "/"
dirpath = "isometric-park-fna/bin/Release"
shutil . rmtree ( new_name )
shutil . copytree ( macos_template , new_name )
for ( dirpath , _dirname , files ) in os . walk ( dirpath ):
for file in files :
source = pathlib . Path ( dirpath ) / file
destination = pathlib . Path ( new_name ) / "Contents" / "Resources" / pathlib . Path ( file )
print ( source , destination )
if source . is_dir () and not destination . exists ():
shutil . copytree ( source , destination )
else :
shutil . copy2 ( source , destination )
shutil . move ( pathlib . Path ( new_name ) / "Contents" / "Resources" / "isometric-park-fna.exe" ,
pathlib . Path ( new_name ) / "Contents" / "Resources" / "isometric-park.exe" )
def main ():
print ( _ , command , arg )
if len ( sys . argv ) > 1 :
command = sys . argv [ 1 ]
if command == "macos" :
if len ( sys . argv ) > 2 :
make_macos ( sys . argv [ 2 ])
else :
pass
if __name__ == '__main__' :
main ()
Site-wide shortcuts
/
Use quick search box
g h
Goto home page
g g
Goto my private gists page
g G
Goto my public gists page
n r
New repository page
n g
New gist page
Repositories
g s
Goto summary page
g c
Goto changelog page
g f
Goto files page
g F
Goto files page with file search activated
g p
Goto pull requests page
g o
Goto repository settings
g O
Goto repository permissions settings