mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
moving datetimestamping responsiblities from mach package
to CI upload, swaps semicolons for dashes
This commit is contained in:
parent
2390503772
commit
d302cf23bc
2 changed files with 7 additions and 12 deletions
|
@ -19,7 +19,6 @@ import subprocess
|
|||
import mako.template
|
||||
|
||||
from mach.registrar import Registrar
|
||||
from datetime import datetime
|
||||
|
||||
from mach.decorators import (
|
||||
CommandArgument,
|
||||
|
@ -155,7 +154,6 @@ class PackageCommands(CommandBase):
|
|||
|
||||
dir_to_build = '/'.join(binary_path.split('/')[:-1])
|
||||
dir_to_root = '/'.join(binary_path.split('/')[:-3])
|
||||
now = datetime.utcnow()
|
||||
|
||||
print("Creating Servo.app")
|
||||
dir_to_dmg = '/'.join(binary_path.split('/')[:-2]) + '/dmg'
|
||||
|
@ -212,9 +210,7 @@ class PackageCommands(CommandBase):
|
|||
print("Creating dmg")
|
||||
os.symlink('/Applications', dir_to_dmg + '/Applications')
|
||||
dmg_path = '/'.join(dir_to_build.split('/')[:-1]) + '/'
|
||||
time = now.replace(microsecond=0).isoformat()
|
||||
time = time.replace(':', '-')
|
||||
dmg_path += time + "-servo-tech-demo.dmg"
|
||||
dmg_path += "servo-tech-demo.dmg"
|
||||
try:
|
||||
subprocess.check_call(['hdiutil', 'create', '-volname', 'Servo', dmg_path, '-srcfolder', dir_to_dmg])
|
||||
except subprocess.CalledProcessError as e:
|
||||
|
@ -229,7 +225,7 @@ class PackageCommands(CommandBase):
|
|||
dir_to_tar = '/'.join(dir_to_build.split('/')[:-1]) + '/brew/'
|
||||
if not path.exists(dir_to_tar):
|
||||
os.makedirs(dir_to_tar)
|
||||
tar_path = dir_to_tar + now.strftime("servo-%Y-%m-%d.tar.gz")
|
||||
tar_path = dir_to_tar + "servo.tar.gz"
|
||||
if path.exists(dir_to_brew):
|
||||
print("Cleaning up from previous packaging")
|
||||
delete(dir_to_brew)
|
||||
|
@ -316,9 +312,7 @@ class PackageCommands(CommandBase):
|
|||
os.close(runservo)
|
||||
|
||||
print("Creating tarball")
|
||||
time = datetime.utcnow().replace(microsecond=0).isoformat()
|
||||
time = time.replace(':', "-")
|
||||
tar_path = path.join(self.get_target_dir(), time + '-servo-tech-demo.tar.gz')
|
||||
tar_path = path.join(self.get_target_dir(), 'servo-tech-demo.tar.gz')
|
||||
|
||||
archive_deterministically(dir_to_temp, tar_path, prepend_path='servo/')
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue