Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: packagerGecko.py

Issue 5430129207541760: Issue 1358 - Publish build tools under the MPL 2.0 license (Closed)
Patch Set: Created Sept. 11, 2014, 3:41 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « packagerChrome.py ('k') | packagerSafari.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # coding: utf-8 1 # coding: utf-8
2 2
3 # This file is part of the Adblock Plus build tools, 3 # This Source Code Form is subject to the terms of the Mozilla Public
4 # Copyright (C) 2006-2014 Eyeo GmbH 4 # License, v. 2.0. If a copy of the MPL was not distributed with this
5 # 5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
6 # Adblock Plus is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License version 3 as
8 # published by the Free Software Foundation.
9 #
10 # Adblock Plus is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
14 #
15 # You should have received a copy of the GNU General Public License
16 # along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
17 6
18 import os, sys, re, hashlib, base64, urllib, json 7 import os, sys, re, hashlib, base64, urllib, json
19 from ConfigParser import SafeConfigParser 8 from ConfigParser import SafeConfigParser
20 from StringIO import StringIO 9 from StringIO import StringIO
21 import xml.dom.minidom as minidom 10 import xml.dom.minidom as minidom
22 import buildtools.localeTools as localeTools 11 import buildtools.localeTools as localeTools
23 12
24 import packager 13 import packager
25 from packager import readMetadata, getMetadataPath, getDefaultFileName, getBuild Version, getTemplate, Files 14 from packager import readMetadata, getMetadataPath, getDefaultFileName, getBuild Version, getTemplate, Files
26 15
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 if metadata.has_section('preprocess'): 324 if metadata.has_section('preprocess'):
336 files.preprocess([f for f, _ in metadata.items('preprocess')]) 325 files.preprocess([f for f, _ in metadata.items('preprocess')])
337 if keyFile: 326 if keyFile:
338 signFiles(files, keyFile) 327 signFiles(files, keyFile)
339 files.zip(outFile, sortKey=lambda x: '!' if x == 'META-INF/zigbert.rsa' else x ) 328 files.zip(outFile, sortKey=lambda x: '!' if x == 'META-INF/zigbert.rsa' else x )
340 329
341 def autoInstall(baseDir, type, host, port, multicompartment=False): 330 def autoInstall(baseDir, type, host, port, multicompartment=False):
342 fileBuffer = StringIO() 331 fileBuffer = StringIO()
343 createBuild(baseDir, type=type, outFile=fileBuffer, multicompartment=multicomp artment) 332 createBuild(baseDir, type=type, outFile=fileBuffer, multicompartment=multicomp artment)
344 urllib.urlopen('http://%s:%s/' % (host, port), data=fileBuffer.getvalue()) 333 urllib.urlopen('http://%s:%s/' % (host, port), data=fileBuffer.getvalue())
OLDNEW
« no previous file with comments | « packagerChrome.py ('k') | packagerSafari.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld