100 ToBI Player-windows安裝

聲明:本軟件來自笑來老師的分享,連接為:https://github.com/xiaolai/tobiplayer,詳細(xì)說明請進(jìn)鏈接內(nèi)Readme說明。

本文是針對windows版本的安裝,步驟如下:

1. 安裝去github 下載最新的 nvm 找到 nvm-setup.zip 點擊下載。

2. 找到nvm安裝路徑 -> 找到 settings.txt 文件 -> 配置下載源,增加兩行:

????node_mirror: https://npm.taobao.org/mirrors/node/

????npm_mirror: https://npm.taobao.org/mirrors/npm/

3. 用nvm看node版本:

????nvm list available

4. 安裝node:

????nvm install 20.5.1

????nvm use 20.5.1

5. 本地先安裝好python3,然后安裝stable-ts庫:

????pip install -U stable-ts

6.下載github至本地:

????git clone https://github.com/xiaolai/tobiplayer.git

注意:

git clone的問題:

修改hosts文件(C:\Windows\System32\drivers\etc),增加:

192.30.255.112? github.com git

185.31.16.184 github.global.ssl.fastly.net?

如有特殊上網(wǎng),設(shè)置與系統(tǒng)代理一樣(注意端口也一樣):

git config --global http.proxy http://127.0.0.1:7890

git config --global https.proxy http://127.0.0.1:7890

都設(shè)置完了可以運行如下(保險,也可不運行)

ipconfig /flushdns

再運行ping github.com就可以了。

7. node編譯:

????cd tobiplayer

????npm install(可用cnpm代替)

????npm run dev(可用cnpm代替)

注意:

1).npm install如出現(xiàn)問題,需要清除緩存,cmd需要以管理員運行,命令:

npm cache clean --force

C:\Users\自己用戶的文件夾\ 下找到 .npmrc 文件并刪除

2).由于網(wǎng)絡(luò)問題,一般可用cnpm代替npm,

npm install -g cnpm --registry=https://registry.npm.taobao.org

這個命令會全局安裝 cnpm,并設(shè)置其使用淘寶的 npm 鏡像源。

3).全局安裝vue,在此 CMD 輸入 npm install -g @vue/cli 就可以成功安裝了

8. 打包為本地:

????npm run build:win(可用cnpm代替)

注意:

1). 運行的時候用于cnpm命令,并且將WaveSurferJS.vue(.\src\renderer\components下)將

import RegionsPlugin from 'wavesurfer.js/dist/plugins/regions.esm.js'

替換為

import RegionsPlugin from '../../../node_modules/.store/wavesurfer.js@7.6.5/node_modules/wavesurfer.js/dist/plugins/regions.esm.js';

2). 可能由于網(wǎng)絡(luò)問題,可能直接打包連接github資源出問題,可以修改electron-builder.json最后增加如下:

......

? ? ? ? "!dist"? ?

? ? ? ? ? ? ? ? ],? ?

? ? ? ? ? ? ? "electronDownload": {? ? ? ?

? ? ? ? ? ? ? "mirror": "https://npm.taobao.org/mirrors/electron/"? ?

? ? ? ? ? ? ? }

}

3).網(wǎng)格問題,在以下頁面中

https://github.com/electron-userland/electron-builder-binaries/releases

需要單獨下載winCodeSign-2.6.0.7z,解壓后連文件夾(帶版本號)拷貝至:

C:\Users\hp\AppData\Local\electron-builder\Cache\winCodeSign

4).同3),在以上網(wǎng)頁中單獨下載nsis-3.0.4.1.zip(注意是source code),解壓后,把兩個文件夾重命名:(nsis -> nsis-3.0.4.1 ) (nsis-resources -> nsis-resources-3.4.1),將這兩個文件夾拷貝至:

C:\Users\hp\AppData\Local\electron-builder\Cache\nsis

運行圖如下:

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容