Include MANIFEST file from FML's universal.jar, makes the jar runnable now!
This commit is contained in:
parent
02e857827d
commit
f9236c4c98
2 changed files with 12 additions and 6 deletions
|
@ -1,6 +0,0 @@
|
||||||
Manifest-Version: 1.0
|
|
||||||
Ant-Version: Apache Ant 1.8.2
|
|
||||||
Created-By: 1.7.0_09-b30 (Oracle Corporation)
|
|
||||||
Main-Class: net.minecraft.server.MinecraftServer
|
|
||||||
Class-Path: minecraft_server.jar
|
|
||||||
|
|
12
release.py
12
release.py
|
@ -70,6 +70,15 @@ def main():
|
||||||
zf.extractall(temp_dir)
|
zf.extractall(temp_dir)
|
||||||
zf.close()
|
zf.close()
|
||||||
|
|
||||||
|
if os.path.isfile('MANIFEST.MF'):
|
||||||
|
os.remove('MANIFEST.MF')
|
||||||
|
|
||||||
|
fml_name = os.path.basename(fml[0]).replace('src', 'universal').replace('.zip', '.jar').replace('-master.', '.')
|
||||||
|
print('Extracting %s MANIFEST.MF' % fml_name)
|
||||||
|
with closing(zipfile.ZipFile(os.path.join(forge_dir, 'fml', 'target', fml_name), mode='r')) as zip_in:
|
||||||
|
with closing(open('MANIFEST.MF', 'wb')) as out:
|
||||||
|
out.write(zip_in.read('META-INF/MANIFEST.MF'))
|
||||||
|
|
||||||
error_level = 0
|
error_level = 0
|
||||||
try:
|
try:
|
||||||
sys.path.append(mcp_dir)
|
sys.path.append(mcp_dir)
|
||||||
|
@ -83,6 +92,7 @@ def main():
|
||||||
print 'Reobfusicate Exception: %d ' % e.code
|
print 'Reobfusicate Exception: %d ' % e.code
|
||||||
error_level = e.code
|
error_level = e.code
|
||||||
|
|
||||||
|
|
||||||
extract_fml_obfed(fml_dir, mcp_dir, reobf_dir, client_dir)
|
extract_fml_obfed(fml_dir, mcp_dir, reobf_dir, client_dir)
|
||||||
#extract_paulscode(mcp_dir, client_dir)
|
#extract_paulscode(mcp_dir, client_dir)
|
||||||
gen_bin_patches(mcp_dir, os.path.join(forge_dir, 'fml'), build_num, client_dir)
|
gen_bin_patches(mcp_dir, os.path.join(forge_dir, 'fml'), build_num, client_dir)
|
||||||
|
@ -173,6 +183,8 @@ def main():
|
||||||
if os.path.exists(version_file):
|
if os.path.exists(version_file):
|
||||||
os.remove(version_file)
|
os.remove(version_file)
|
||||||
shutil.rmtree(temp_dir)
|
shutil.rmtree(temp_dir)
|
||||||
|
if os.path.isfile('MANIFEST.MF'):
|
||||||
|
os.remove('MANIFEST.MF')
|
||||||
|
|
||||||
print '=================================== Release Finished %d =================================' % error_level
|
print '=================================== Release Finished %d =================================' % error_level
|
||||||
sys.exit(error_level)
|
sys.exit(error_level)
|
||||||
|
|
Loading…
Reference in a new issue