update
This commit is contained in:
		
							parent
							
								
									a30664b060
								
							
						
					
					
						commit
						3ef857725e
					
				
							
								
								
									
										17
									
								
								build.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								build.py
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,17 @@ | |||||||
|  | import os | ||||||
|  | import subprocess | ||||||
|  | import shutil | ||||||
|  | import sys | ||||||
|  | 
 | ||||||
|  | script_dir = os.path.dirname(os.path.abspath(__file__)) | ||||||
|  | source_dir = os.path.join(script_dir,"webp_to_png","data") | ||||||
|  | des_dir = os.path.join(source_dir,"dist","pyinstaller") | ||||||
|  | if sys.platform.startswith('win32'): | ||||||
|  |     des_dir = os.path.join(des_dir,"win_amd64") | ||||||
|  |     print("You are on the windows platform,it will put data into",des_dir) | ||||||
|  | else: | ||||||
|  |     print("you are on the other platform please put webp_to_png/data \"data\" directory into the exe directory") | ||||||
|  | 
 | ||||||
|  | subprocess.run(["poetry","build"], check=True) | ||||||
|  | 
 | ||||||
|  | shutil.copytree(source_dir,des_dir) | ||||||
| @ -1,9 +1,9 @@ | |||||||
| [tool.poetry-pyinstaller-plugin.scripts] | [tool.poetry-pyinstaller-plugin.scripts] | ||||||
| webp_to_png = { source = "webp_to_png/__main__.pyw", type = "onefile", bundle = false, icon="../../../../favicon.ico"} | webp_to_png = { source = "webp_to_png/__main__.pyw", type = "onefile", bundle = false, icon="../../../../webp_to_png/data/favicon.ico", console=true} | ||||||
| 
 | 
 | ||||||
| [tool.poetry-pyinstaller-plugin.collect] | # [tool.poetry-pyinstaller-plugin.collect] | ||||||
| # Collect all submodules, data files & binaries for 'package_A' and 'package_B' | # Collect all submodules, data files & binaries for 'package_A' and 'package_B' | ||||||
| data = ["webp_to_png"] | # all = ["webp_to_png"] | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| [tool.poetry] | [tool.poetry] | ||||||
|  | |||||||
| Before Width: | Height: | Size: 162 KiB After Width: | Height: | Size: 162 KiB | 
										
											Binary file not shown.
										
									
								
							| Before Width: | Height: | Size: 162 KiB | 
		Loading…
	
		Reference in New Issue
	
	Block a user