[Seek Help] 如何给ariaNg弄一个快捷方式图标
Tofloor
poster avatar
与风长舞的叶
deepin
2022-01-10 05:33
Author

目前的打开方式:双击index.html,然后再点击一下显示,

能直接弄一个快捷方式的吗,点一下就好的那种?

图片.png

图片.png

Reply Favorite View the author
All Replies
Maicss
deepin
2022-01-10 05:59
#1

写一个desktop

exec的部分就写xdg-open+空格+你的index文件路径

例如ariang.desktop

[Desktop Entry]
Name=AriaNg
Icon=/home/maicss/AriaNg/touchicon.png
Exec=xdg-open /home/maicss/AriaNg/index.html

放在/usr/share/applications或者~/.local/share/applications/里边

按理说应该就行了

Reply View the author
翻过山峰看见云
deepin
2022-01-10 17:28
#2

我一直都用的在线的那个网页,从来都不知道还可以这么用

Reply View the author
与风长舞的叶
deepin
2022-01-10 21:01
#3
翻过山峰看见云

我一直都用的在线的那个网页,从来都不知道还可以这么用

弄个快捷方式方便

Reply View the author
神末shenmo
deepin
Spark-App
Q&A Team
2022-01-11 02:10
#4

这是什么软件?能否分享下?

Reply View the author
与风长舞的叶
deepin
2022-01-11 04:47
#5
神末shenmo

这是什么软件?能否分享下?

大神,这是aria2的网页前端,叫ariaNg,github上有的;

我是在B站弄来的,网址,【5分钟学会如何在Linux部署使用下载神器--Aria2-哔哩哔哩】 https://b23.tv/zRimzxt

Reply View the author
与风长舞的叶
deepin
2022-01-11 06:05
#6
Maicss

写一个desktop

exec的部分就写xdg-open+空格+你的index文件路径

例如ariang.desktop

[Desktop Entry]
Name=AriaNg
Icon=/home/maicss/AriaNg/touchicon.png
Exec=xdg-open /home/maicss/AriaNg/index.html

放在/usr/share/applications或者~/.local/share/applications/里边

按理说应该就行了

如下图,双击图标打不开

图片.png

Reply View the author
Maicss
deepin
2022-01-11 16:33
#7
与风长舞的叶

如下图,双击图标打不开

图片.png

直接在命令行运行exec里边的内容可以吗?

如果可以那就在里边加一行

Type=Application

试试

Reply View the author
神末shenmo
deepin
Spark-App
Q&A Team
2022-01-12 01:02
#8

如果你想在双击时直接显示,右键属性--->权限管理--->取消勾选允许以程序执行

Reply View the author
与风长舞的叶
deepin
2022-01-12 03:31
#9
Maicss

直接在命令行运行exec里边的内容可以吗?

如果可以那就在里边加一行

Type=Application

试试

加上 Type=Application后可以了。

然后,还能不能更进阶一点,打开这个快捷方式,自动启动aria2😂

Reply View the author
Maicss
deepin
2022-01-12 03:39
#10
与风长舞的叶

加上 Type=Application后可以了。

然后,还能不能更进阶一点,打开这个快捷方式,自动启动aria2😂

可以,要执行多条命令可以用&&连接起来

Exec=xdg-open /home/maicss/AriaNg/index.html && /path/to/aria2

Reply View the author
与风长舞的叶
deepin
2022-01-12 04:38
#11
Maicss

可以,要执行多条命令可以用&&连接起来

Exec=xdg-open /home/maicss/AriaNg/index.html && /path/to/aria2

1、我的desktop这样写的,aria2无法启动,网页前端也打不开,把&&后的删掉就可以打开前端

[Desktop Entry] Name=AriaNg Icon=/home/faeling/Downloads/AriaNg-1.2.3/touchicon.png Exec=xdg-open /home/faeling/Downloads/AriaNg-1.2.3/index.html && aria2c --conf-path=/home/faeling/Downloads/aria2/aria2.conf Type=Application

2、然后在终端中运行这个,也无法启动aria2,得先cd到配置的目录,就能启动

aria2c --conf-path=/home/faeling/Downloads/aria2/aria2.conf 捕捉到异常 Exception: [download_helper.cc:563] errorCode=1 打开文件 aria2.session 失败,原因:File not found or it is a directory

图片.png

Reply View the author