mirror of
https://github.com/TriM-Organization/Musicreater.git
synced 2024-11-11 01:27:35 +08:00
将对于Windows的限制全部去除
This commit is contained in:
parent
f86879a673
commit
af3c7432ed
@ -37,12 +37,13 @@ __author__ = 'W-YI (金羿)'
|
||||
|
||||
import sys
|
||||
|
||||
if sys.platform != 'win32':
|
||||
print("您当前的运行环境不符合要求。")
|
||||
print(__author__+" 音·创 当前版本"+__version__)
|
||||
print("按下回车退出程序")
|
||||
input()
|
||||
exit()
|
||||
|
||||
# if sys.platform != 'win32':
|
||||
# print("您当前的运行环境不符合要求。")
|
||||
# print(__author__+" 音·创 当前版本"+__version__)
|
||||
# print("按下回车退出程序")
|
||||
# input()
|
||||
# exit()
|
||||
|
||||
|
||||
|
||||
@ -164,19 +165,6 @@ def __main__():
|
||||
|
||||
print("音·创 正在启动……")
|
||||
|
||||
'''
|
||||
from nmcsup.vers import chkver
|
||||
print("检验或下载支持库")
|
||||
chkver()
|
||||
'''
|
||||
|
||||
|
||||
|
||||
print("更新执行位置...")
|
||||
os.chdir(__file__[:len(__file__)-__file__[len(__file__)::-1].index('\\')])
|
||||
print('完成!')
|
||||
|
||||
|
||||
|
||||
|
||||
print('载入日志功能...')
|
||||
@ -185,6 +173,17 @@ def __main__():
|
||||
|
||||
|
||||
|
||||
print("更新执行位置...")
|
||||
if sys.platform == 'win32':
|
||||
os.chdir(__file__[:len(__file__)-__file__[len(__file__)::-1].index('\\')])
|
||||
log("更新执行位置,当前文件位置"+__file__)
|
||||
else:
|
||||
os.chdir(__file__[:len(__file__)-__file__[len(__file__)::-1].index('/')])
|
||||
log("其他平台:更新执行位置,当前文件位置"+__file__)
|
||||
print('完成!')
|
||||
|
||||
|
||||
|
||||
|
||||
# 读取文件
|
||||
|
||||
|
@ -10,8 +10,8 @@ Copyright © W-YI 2021
|
||||
1.可以导出自定义的结构文件用于存储要导入地图中的结构
|
||||
2.进度条
|
||||
3.可以将音乐写入音符盒(红乐)
|
||||
4.更换tk库为briefcase库
|
||||
5.支持安卓系统
|
||||
4.更换tk库为briefcase库,支持安卓系统
|
||||
5.支持自动给音符盒绑定更多的音色
|
||||
6.可以由.schematic文件导入地图,亦可反向处理
|
||||
7.支持自定义指令方块区域的长宽高等
|
||||
8.支持自定义创建websockeet服务器播放音乐(感谢由 Fuckcraft <https://gitee.com/fuckcraft> “鸣凤鸽子”等 带来的我的世界websocket服务器功能)
|
||||
|
@ -1,5 +1,5 @@
|
||||
# -*- coding: UTF-8 -*-
|
||||
'''提供错误报告的基本操作及方法'''
|
||||
'''提供错误报告的基本操作及方法 顺便提供版本更新、安装库等功能'''
|
||||
|
||||
|
||||
|
||||
@ -93,3 +93,32 @@ def emailReport(senderName:str = 'Unknown',senderContact:str = 'None',describeti
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
class version:
|
||||
|
||||
libraries = ('mido','amulet','amulet-core','amulet-nbt','piano_transcription_inference','pypinyin','briefcase','toga','pyinstaller','kivy','py7zr')
|
||||
'''当前所需库,有一些是开发用的,用户不需要安装'''
|
||||
|
||||
version = ('0.0.3.5','Beta',)
|
||||
'''当前版本'''
|
||||
|
||||
def __init__(self) -> None:
|
||||
|
||||
self.libraries = version.libraries
|
||||
'''当前所需库,有一些是开发用的,用户不需要安装'''
|
||||
|
||||
self.version = version.version
|
||||
'''当前版本'''
|
||||
|
||||
def installLibraries(self):
|
||||
'''安装全部开发用库'''
|
||||
from sys import platform
|
||||
import os
|
||||
if platform == 'win32':
|
||||
import shutil
|
||||
shutil.rmtree(os.getenv('APPDATA')+'\\Musicreater\\')
|
||||
for i in self.libraries:
|
||||
print("安装库:"+i)
|
||||
os.system("python -m pip install "+i+" -i https://pypi.tuna.tsinghua.edu.cn/simple")
|
||||
|
@ -2,11 +2,14 @@
|
||||
|
||||
|
||||
|
||||
from msctspt.bugReporter import version
|
||||
|
||||
VER = ('0.0.3.4','Beta',)
|
||||
|
||||
#以下下两个值请在 msctspt/bugReporter 的version类中修改
|
||||
VER = version.version
|
||||
'''当前版本'''
|
||||
|
||||
LIBS = ('mido','amulet','amulet-core','amulet-nbt','piano_transcription_inference','pypinyin','briefcase','toga','pyinstaller','kivy','py7zr')
|
||||
LIBS = version.libraries
|
||||
'''当前所需库'''
|
||||
|
||||
|
||||
@ -46,8 +49,8 @@ def compver(ver1, ver2):
|
||||
import os
|
||||
|
||||
def InstallLibs(now,LIBS):
|
||||
from os import system as run
|
||||
'''比对库信息并安装库'''
|
||||
from os import system as run
|
||||
for i in LIBS:
|
||||
if not i in now:
|
||||
print("安装库:"+i)
|
||||
|
@ -1,3 +0,0 @@
|
||||
import sys
|
||||
print("当前\n"+sys.executable+"\n版本为:\n"+sys.version)
|
||||
input()
|
@ -1,2 +1,2 @@
|
||||
from nmcsup.vers import chkver
|
||||
chkver()
|
||||
from msctspt.bugReporter import version
|
||||
version.installLibraries()
|
Loading…
Reference in New Issue
Block a user