build: 增量更新版本判断
							parent
							
								
									4345c23d96
								
							
						
					
					
						commit
						e55f67c78b
					
				| 
						 | 
				
			
			@ -1,4 +1,4 @@
 | 
			
		|||
!macro customUnInit
 | 
			
		||||
  MessageBox MB_OK "卸载前请务必手动右下角小图标退出DevSidecar之后,再进行下一步(如果已经退出请忽略)↘↘↘↘↘↘↘↘↘"
 | 
			
		||||
  MessageBox MB_OK "卸载前请务必手动退出DevSidecar之后,再进行下一步(如果已经退出请忽略)"
 | 
			
		||||
  ExecWait '"$INSTDIR\resources\extra\sysproxy.exe" set 1'
 | 
			
		||||
!macroend
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,6 +1,6 @@
 | 
			
		|||
{
 | 
			
		||||
  "name": "@docmirror/dev-sidecar-gui",
 | 
			
		||||
  "version": "1.7.2",
 | 
			
		||||
  "version": "1.6.9",
 | 
			
		||||
  "private": false,
 | 
			
		||||
  "license": "MPL-2.0",
 | 
			
		||||
  "main": "background.js",
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -83,14 +83,14 @@ function install (app, api) {
 | 
			
		|||
   * @param version2
 | 
			
		||||
   */
 | 
			
		||||
  async function isSupportPartUpdate (value) {
 | 
			
		||||
    const info = await api.info.get()
 | 
			
		||||
    console.log('升级版本:', value.version)
 | 
			
		||||
    console.log('增量更新最小版本:', value.partMiniVersion)
 | 
			
		||||
    console.log('当前版本:', info.version)
 | 
			
		||||
    if (!value.partPackage) {
 | 
			
		||||
      return false
 | 
			
		||||
    }
 | 
			
		||||
    const info = await this.$api.info.get()
 | 
			
		||||
    if (value.partMiniVersion && value.partMiniVersion < info.version) {
 | 
			
		||||
      return true
 | 
			
		||||
    }
 | 
			
		||||
    return false
 | 
			
		||||
    return !!(value.partMiniVersion && value.partMiniVersion < info.version)
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  async function downloadNewVersion (value) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -2,6 +2,3 @@ const CryptoJs = require('crypto-js')
 | 
			
		|||
const ret = CryptoJs.SHA256('111111111111')
 | 
			
		||||
console.log(ret.toString(CryptoJs.enc.Base64))
 | 
			
		||||
console.log(1 / 2)
 | 
			
		||||
 | 
			
		||||
const version1 = '1.7.0'
 | 
			
		||||
console.log(version1.substring(0, version1.lastIndexOf('.')))
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue