提交 e12e61ed authored 作者: 蔡芬's avatar 蔡芬

1

上级 ffd26121
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
"js-cookie": "^3.0.1", "js-cookie": "^3.0.1",
"node-machine-id": "^1.1.12", "node-machine-id": "^1.1.12",
"pbkdf2": "3.1.1", "pbkdf2": "3.1.1",
"pinyin": "^3.0.0-alpha.4",
"unsplash-js": "^7.0.15", "unsplash-js": "^7.0.15",
"vue": "^2.6.11", "vue": "^2.6.11",
"vue-clipboard2": "^0.3.3", "vue-clipboard2": "^0.3.3",
......
...@@ -108,15 +108,22 @@ class SoftList { ...@@ -108,15 +108,22 @@ class SoftList {
const noDisplayLine = lines.find(line => line.startsWith('NoDisplay=')); const noDisplayLine = lines.find(line => line.startsWith('NoDisplay='));
const noDisplay = noDisplayLine ? noDisplayLine.substr(10) : null; const noDisplay = noDisplayLine ? noDisplayLine.substr(10) : null;
console.log('execMatch', execMatch) // console.log('execMatch', execMatch)
let execCommand = ''; let execCommand = '';
let execArr = [];
if(execMatch) { if(execMatch) {
execArr = lines.filter(v => v.startsWith('Exec='));
execCommand = execMatch[1]; execCommand = execMatch[1];
let targetIndex = execArr.findIndex(v => (v.indexOf('%') == -1 || v.indexOf('%U') == -1));
if(execArr.length>1) console.log(execArr)
if(targetIndex >= 0) {
execCommand = execArr[targetIndex].replace('Exec=', '');
}
}else { }else {
const execLine = lines.find(line => line.startsWith('Exec=')); const execLine = lines.find(line => line.startsWith('Exec='));
execCommand = execLine ? execLine.substr(5) : null; execCommand = execLine ? execLine.substr(5) : null;
} }
console.log('execCommand', execCommand)
let iconList = []; let iconList = [];
// icon判断是否绝对路径 // icon判断是否绝对路径
if( icon && !path.isAbsolute( icon ) ) { if( icon && !path.isAbsolute( icon ) ) {
......
差异被折叠。
Markdown 格式
0% 或
您添加了 0 人 到此讨论。请谨慎行事。
请先完成此评论的编辑!
请 注册 或者 后发表评论