mirror of
https://gitee.com/spark-store-project/spark-store
synced 2025-12-15 21:32:05 +08:00
Compare commits
49 Commits
3.2.1
...
3.2.4test2
| Author | SHA1 | Date | |
|---|---|---|---|
| 3feec88f7b | |||
| c0ffb64a86 | |||
| 8c08b7e995 | |||
| 4d7e766d75 | |||
| 09115c3961 | |||
| 63998bbce4 | |||
| 967f62f825 | |||
| e8ae0325e0 | |||
| 66a4563b51 | |||
| 330ae3eeb8 | |||
| 0534c39ee5 | |||
| 04047c1e44 | |||
| 5e501b9d17 | |||
| 5a434a9b7d | |||
| e554aec98d | |||
| ab0f5e6613 | |||
| 59607f6b34 | |||
| a13f0ddcb7 | |||
| fec604b481 | |||
| 085eddd66f | |||
| 30860802dd | |||
| 30f36ff35d | |||
|
|
81993625ba | ||
| 87b68aca1e | |||
| 10125c5816 | |||
| 21d33ec347 | |||
| ad57aa26ff | |||
| 8902c81b9e | |||
| 0ad4b6c82c | |||
| 189a0b4939 | |||
| c65d7b86df | |||
| e269e6ca57 | |||
| aff593eba8 | |||
| beaeac60a3 | |||
| 11d68fb4b5 | |||
| e7680fe2a0 | |||
| 19dff7fb56 | |||
| 67b314d0d2 | |||
| 63b28adaf8 | |||
| 8741973cca | |||
| 8e3787ab07 | |||
| f7d07e0bf9 | |||
| 9e4df5c5c2 | |||
| 829a08d40a | |||
| 411bbe5935 | |||
| 5d5fbfbad4 | |||
| c93c221cf1 | |||
| afee0966c8 | |||
| 2df5363c2c |
@@ -12,8 +12,10 @@ All packages will be shared in our repository for users to get freely.
|
|||||||
Distrobution supported:Deepin 20 ; Ubuntu 22.04 LTS / Ubuntu 20.04 LTS(May stop support in the future) ; UniontechOS Home 21
|
Distrobution supported:Deepin 20 ; Ubuntu 22.04 LTS / Ubuntu 20.04 LTS(May stop support in the future) ; UniontechOS Home 21
|
||||||
|
|
||||||
|
|
||||||
|
You can track our Issue resoving progress here https://gitee.com/deepin-community-store/spark-store/board
|
||||||
|
|
||||||
I hope people who see here can also join our team,development help or submit applications are welcomed
|
|
||||||
|
We hope people who see here can also join our team,development help or submit applications are welcomed
|
||||||
|
|
||||||
If you want to submit an APP to share with others,Please [Click here](https://upload.deepinos.org/index)
|
If you want to submit an APP to share with others,Please [Click here](https://upload.deepinos.org/index)
|
||||||
|
|
||||||
|
|||||||
@@ -10,6 +10,8 @@
|
|||||||
|
|
||||||
希望看到这里的人也可以加入我们的队伍,开发或者投递应用都很欢迎,共同构建Linux应用生态
|
希望看到这里的人也可以加入我们的队伍,开发或者投递应用都很欢迎,共同构建Linux应用生态
|
||||||
|
|
||||||
|
在这里追踪我们的Issue处理情况 https://gitee.com/deepin-community-store/spark-store/board
|
||||||
|
|
||||||
如果有想要提交的软件包,请 [在这里投稿](https://upload.deepinos.org/index)
|
如果有想要提交的软件包,请 [在这里投稿](https://upload.deepinos.org/index)
|
||||||
|
|
||||||
|
|
||||||
@@ -26,7 +28,7 @@
|
|||||||
Deepin V20/UOS 21 系统下, 安装依赖
|
Deepin V20/UOS 21 系统下, 安装依赖
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
sudo apt install git qt5-default debhelper pkg-config qtchooser libqt5core5a libqt5gui5 libqt5widgets5 libqt5network5 libqt5concurrent5 libdtkcore-dev libdtkgui-dev libdtkwidget-dev qttools5-private-dev libnotify-dev qtwebengine5-dev
|
sudo apt install git qt5-default debhelper pkg-config qtchooser libqt5core5a libqt5gui5 libqt5widgets5 libqt5network5 libqt5concurrent5 libdtkcore-dev libdtkgui-dev libdtkwidget-dev qttools5-private-dev libnotify-dev qtwebengine5-dev fakeroot
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
31
debian/changelog
vendored
31
debian/changelog
vendored
@@ -1,3 +1,34 @@
|
|||||||
|
spark-store (3.2.4~test2) stable; urgency=medium
|
||||||
|
|
||||||
|
* 客户端集成投稿器入口和支持
|
||||||
|
* 修复:安装依赖时间较长时错误地返回“安装完毕”结果
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
-- shenmo <shenmo@spark-app.store> Fri, 30 Jan 2022 00:00:00 +0800
|
||||||
|
|
||||||
|
spark-store (3.2.4~test1) stable; urgency=medium
|
||||||
|
|
||||||
|
* 客户端更新时不关闭免密码登录
|
||||||
|
* UOS合并正常aptss中
|
||||||
|
|
||||||
|
|
||||||
|
-- shenmo <shenmo@spark-app.store> Fri, 30 Jan 2022 00:00:00 +0800
|
||||||
|
|
||||||
|
spark-store (3.2.3) stable; urgency=medium
|
||||||
|
|
||||||
|
* 客户端异常退出时仍然占用资源问题修复
|
||||||
|
* 降低dtk依赖版本,Debian 11 stable可直接安装
|
||||||
|
|
||||||
|
-- shenmo <shenmo@spark-app.store> Fri, 30 Jan 2022 00:00:00 +0800
|
||||||
|
|
||||||
|
spark-store (3.2.2) stable; urgency=medium
|
||||||
|
|
||||||
|
* aptss will now refresh the system source before doing install, policy....etc
|
||||||
|
* 启动客户端GPU加速支持
|
||||||
|
|
||||||
|
-- shenmo <shenmo@spark-app.store> Fri, 30 Jan 2022 00:00:00 +0800
|
||||||
|
|
||||||
spark-store (3.2.1) stable; urgency=medium
|
spark-store (3.2.1) stable; urgency=medium
|
||||||
|
|
||||||
* 更改刷新系统源的功能
|
* 更改刷新系统源的功能
|
||||||
|
|||||||
6
debian/control
vendored
6
debian/control
vendored
@@ -11,9 +11,9 @@ Build-Depends:
|
|||||||
libqt5widgets5,
|
libqt5widgets5,
|
||||||
libqt5network5,
|
libqt5network5,
|
||||||
libqt5concurrent5,
|
libqt5concurrent5,
|
||||||
libdtkcore-dev(>=5.2),
|
libdtkcore-dev(>=5.0),
|
||||||
libdtkgui-dev(>=5.2),
|
libdtkgui-dev(>=5.0),
|
||||||
libdtkwidget-dev(>=5.2),
|
libdtkwidget-dev(>=5.0),
|
||||||
qttools5-private-dev,
|
qttools5-private-dev,
|
||||||
libnotify-dev,
|
libnotify-dev,
|
||||||
qtwebengine5-dev
|
qtwebengine5-dev
|
||||||
|
|||||||
6
debian/spark-store.prerm
vendored
6
debian/spark-store.prerm
vendored
@@ -1,5 +1,6 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ "$1" = "remove" ] || [ "$1" = "purge" ];then
|
||||||
# Remove residual symbol links
|
# Remove residual symbol links
|
||||||
rm /usr/local/bin/spark-store
|
rm /usr/local/bin/spark-store
|
||||||
rm /usr/local/bin/ssinstall
|
rm /usr/local/bin/ssinstall
|
||||||
@@ -39,3 +40,8 @@ fi
|
|||||||
|
|
||||||
apt-key del '9D9A A859 F750 24B1 A1EC E16E 0E41 D354 A29A 440C'
|
apt-key del '9D9A A859 F750 24B1 A1EC E16E 0E41 D354 A29A 440C'
|
||||||
|
|
||||||
|
else
|
||||||
|
|
||||||
|
echo "非卸载操作,不进行配置清理"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|||||||
@@ -6,4 +6,4 @@ Subject: spark-store_3.0.2: $(lsb_release -a | grep "Description" | sed -e "s#\t
|
|||||||
|
|
||||||
$(uname -a)" | tee /tmp/spark-store-install/feedback.txt > /dev/null
|
$(uname -a)" | tee /tmp/spark-store-install/feedback.txt > /dev/null
|
||||||
|
|
||||||
curl -s --url "smtp://smtp.163.com" --mail-from "sparkstorefeedback@163.com" --mail-rcpt "sparkstorefeedback@163.com" --upload-file /tmp/spark-store-install/feedback.txt --user "sparkstorefeedback@163.com:YWYGLQNOPLWNNJJY"
|
curl -s --url "smtp://smtp.163.com" --mail-from "${MAIL_FEEDBACK}" --mail-rcpt "${MAIL_FEEDBACK}" --upload-file /tmp/spark-store-install/feedback.txt --user "${MAIL_FEEDBACK}:${M}AIL_AUTH"
|
||||||
|
|||||||
@@ -151,7 +151,7 @@ void downloadlist::install(int t)
|
|||||||
|
|
||||||
bool haveError = false;
|
bool haveError = false;
|
||||||
bool notRoot = false;
|
bool notRoot = false;
|
||||||
installer.waitForFinished();
|
installer.waitForFinished(-1); // 不设置超时
|
||||||
out = installer.readAllStandardOutput();
|
out = installer.readAllStandardOutput();
|
||||||
|
|
||||||
QStringList everyOut = out.split("\n");
|
QStringList everyOut = out.split("\n");
|
||||||
@@ -169,7 +169,7 @@ void downloadlist::install(int t)
|
|||||||
|
|
||||||
QProcess isInstall;
|
QProcess isInstall;
|
||||||
isInstall.start("dpkg -s " + pkgName);
|
isInstall.start("dpkg -s " + pkgName);
|
||||||
isInstall.waitForFinished();
|
isInstall.waitForFinished(180); // 默认超时 3 分钟
|
||||||
int error = QString::fromStdString(isInstall.readAllStandardError().toStdString()).length();
|
int error = QString::fromStdString(isInstall.readAllStandardError().toStdString()).length();
|
||||||
if(error == 0)
|
if(error == 0)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -13,6 +13,10 @@ int main(int argc, char *argv[])
|
|||||||
DApplication::loadDXcbPlugin(); // 已废弃,但是对于非deepin桌面可以正常使用标题栏
|
DApplication::loadDXcbPlugin(); // 已废弃,但是对于非deepin桌面可以正常使用标题栏
|
||||||
DApplication::setAttribute(Qt::AA_EnableHighDpiScaling); // 开启 Hidpi 支持
|
DApplication::setAttribute(Qt::AA_EnableHighDpiScaling); // 开启 Hidpi 支持
|
||||||
// 程序内强制添加"-platformtheme deepin"参数喂给Qt让Qt正确使用Deepin主题修复各种奇怪样式问题
|
// 程序内强制添加"-platformtheme deepin"参数喂给Qt让Qt正确使用Deepin主题修复各种奇怪样式问题
|
||||||
|
|
||||||
|
// 浏览器开启 GPU 支持
|
||||||
|
qputenv("QTWEBENGINE_CHROMIUM_FLAGS", "--ignore-gpu-blocklist --enable-gpu-rasterization --enable-native-gpu-memory-buffers --enable-accelerated-video-decode");
|
||||||
|
|
||||||
QVector<char*> fakeArgs(argc + 2);
|
QVector<char*> fakeArgs(argc + 2);
|
||||||
fakeArgs[0] = argv[0];
|
fakeArgs[0] = argv[0];
|
||||||
fakeArgs[1] = "-platformtheme";
|
fakeArgs[1] = "-platformtheme";
|
||||||
@@ -30,7 +34,7 @@ int main(int argc, char *argv[])
|
|||||||
DAboutDialog dialog;
|
DAboutDialog dialog;
|
||||||
a.setAboutDialog(&dialog);
|
a.setAboutDialog(&dialog);
|
||||||
dialog.setLicense(QObject::tr("We publish this program under GPL V3"));
|
dialog.setLicense(QObject::tr("We publish this program under GPL V3"));
|
||||||
dialog.setVersion(DApplication::buildVersion("Version 3.2.1"));
|
dialog.setVersion(DApplication::buildVersion("Version 3.2.4"));
|
||||||
dialog.setProductIcon(QIcon::fromTheme("spark-store")); // 设置Logo
|
dialog.setProductIcon(QIcon::fromTheme("spark-store")); // 设置Logo
|
||||||
dialog.setProductName(QLabel::tr("Spark Store"));
|
dialog.setProductName(QLabel::tr("Spark Store"));
|
||||||
dialog.setDescription(
|
dialog.setDescription(
|
||||||
@@ -51,7 +55,7 @@ int main(int argc, char *argv[])
|
|||||||
a.setOrganizationName("spark-union");
|
a.setOrganizationName("spark-union");
|
||||||
a.setOrganizationDomain("https://www.deepinos.org/");
|
a.setOrganizationDomain("https://www.deepinos.org/");
|
||||||
a.setApplicationName("Spark Store"); //不需要翻译,否则 ~/.local/share/ 下文件夹名称也被翻译为中文
|
a.setApplicationName("Spark Store"); //不需要翻译,否则 ~/.local/share/ 下文件夹名称也被翻译为中文
|
||||||
a.setApplicationVersion(DApplication::buildVersion("3.2.1"));
|
a.setApplicationVersion(DApplication::buildVersion("3.2.4"));
|
||||||
a.setApplicationAcknowledgementPage("https://gitee.com/deepin-community-store/spark-store");
|
a.setApplicationAcknowledgementPage("https://gitee.com/deepin-community-store/spark-store");
|
||||||
a.setApplicationDescription(
|
a.setApplicationDescription(
|
||||||
QObject::tr(
|
QObject::tr(
|
||||||
|
|||||||
@@ -18,6 +18,7 @@
|
|||||||
#include <QSettings>
|
#include <QSettings>
|
||||||
#include <QGraphicsOpacityEffect>
|
#include <QGraphicsOpacityEffect>
|
||||||
#include <QtConcurrent> // 并发
|
#include <QtConcurrent> // 并发
|
||||||
|
#include <QCloseEvent> // close event
|
||||||
|
|
||||||
#include <DApplication>
|
#include <DApplication>
|
||||||
#include <DGuiApplicationHelper>
|
#include <DGuiApplicationHelper>
|
||||||
@@ -192,6 +193,7 @@ void Widget::initUI()
|
|||||||
|
|
||||||
// 添加菜单项
|
// 添加菜单项
|
||||||
QAction *actionSubmission = new QAction(tr("Submit App"), this);
|
QAction *actionSubmission = new QAction(tr("Submit App"), this);
|
||||||
|
QAction *actionSubmissionWithClient = new QAction(tr("Submit App with client(Recommanded)"), this);
|
||||||
QAction *setting = new QAction(tr("Settings"));
|
QAction *setting = new QAction(tr("Settings"));
|
||||||
QAction *upgrade = new QAction(tr("APP Upgrade and Install Settings"));
|
QAction *upgrade = new QAction(tr("APP Upgrade and Install Settings"));
|
||||||
|
|
||||||
@@ -199,6 +201,7 @@ void Widget::initUI()
|
|||||||
menu->addAction(setting);
|
menu->addAction(setting);
|
||||||
menu->addAction(upgrade);
|
menu->addAction(upgrade);
|
||||||
menu->addAction(actionSubmission);
|
menu->addAction(actionSubmission);
|
||||||
|
menu->addAction(actionSubmissionWithClient);
|
||||||
|
|
||||||
titlebar->setMenu(menu);
|
titlebar->setMenu(menu);
|
||||||
|
|
||||||
@@ -206,6 +209,23 @@ void Widget::initUI()
|
|||||||
connect(setting, &QAction::triggered, this, &Widget::opensetting);
|
connect(setting, &QAction::triggered, this, &Widget::opensetting);
|
||||||
connect(upgrade, &QAction::triggered, this, [=]{QProcess::startDetached("x-terminal-emulator -e /opt/durapps/spark-store/bin/update-upgrade/ss-update-controler.sh");});
|
connect(upgrade, &QAction::triggered, this, [=]{QProcess::startDetached("x-terminal-emulator -e /opt/durapps/spark-store/bin/update-upgrade/ss-update-controler.sh");});
|
||||||
|
|
||||||
|
// 投稿器
|
||||||
|
connect(actionSubmissionWithClient, &QAction::triggered, this, [=]
|
||||||
|
{
|
||||||
|
QString submitterSpk = "spk://store/tools/spark-store-submitter";
|
||||||
|
QFile actionSubmissionClientStatus("/opt/spark-store-submitter/bin/spark-store-submitter");
|
||||||
|
if (actionSubmissionClientStatus.exists())
|
||||||
|
{
|
||||||
|
qDebug() << "投稿器存在";
|
||||||
|
QProcess::startDetached("/opt/spark-store-submitter/bin/spark-store-submitter");
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
qDebug() << "投稿器不存在,跳转页面";
|
||||||
|
openUrl(submitterSpk);
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
// 载入自定义字体
|
// 载入自定义字体
|
||||||
int loadedFontID = QFontDatabase::addApplicationFont(":/fonts/fonts/hksnzt.ttf");
|
int loadedFontID = QFontDatabase::addApplicationFont(":/fonts/fonts/hksnzt.ttf");
|
||||||
QStringList loadedFontFamilies = QFontDatabase::applicationFontFamilies(loadedFontID);
|
QStringList loadedFontFamilies = QFontDatabase::applicationFontFamilies(loadedFontID);
|
||||||
@@ -572,14 +592,14 @@ void Widget::chooseLeftMenu(int index)
|
|||||||
|
|
||||||
updateUI();
|
updateUI();
|
||||||
|
|
||||||
if(index <= 12)
|
if (index <= 12)
|
||||||
{
|
{
|
||||||
if(themeIsDark)
|
if (themeIsDark)
|
||||||
{
|
{
|
||||||
QString darkurl = menuUrl[index].toString();
|
QString darkurl = menuUrl[index].toString();
|
||||||
QStringList list = darkurl.split("/");
|
QStringList list = darkurl.split("/");
|
||||||
darkurl.clear();
|
darkurl.clear();
|
||||||
for(int i = 0; i < list.size() - 1; i++)
|
for (int i = 0; i < list.size() - 1; i++)
|
||||||
{
|
{
|
||||||
darkurl += list[i] + "/";
|
darkurl += list[i] + "/";
|
||||||
}
|
}
|
||||||
@@ -687,22 +707,18 @@ void Widget::searchApp(QString text)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// sendNotification(tr("Spark store could only process spk:// links for now. The search feature is coming soon!"));
|
|
||||||
// ui->webView->setUrl(QUrl("http://www.baidu.com/s?wd="+text)); // 这东西对接百度
|
|
||||||
// ui->stackedWidget->setCurrentIndex(0);
|
|
||||||
|
|
||||||
// 禁止同时进行多次搜索
|
// 禁止同时进行多次搜索
|
||||||
if(!mutex.tryLock())
|
if (!mutex.tryLock())
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 关键字搜索处理
|
// 关键字搜索处理
|
||||||
httpClient->get("https://search.deepinos.org.cn/appinfo/search")
|
httpClient->get("https://search.deepinos.org.cn/appinfo/search")
|
||||||
.header("content-type", "application/json")
|
.header("content-type", "application/json")
|
||||||
.queryParam("keyword", text)
|
.queryParam("keyword", text)
|
||||||
.onResponse([this](QByteArray result)
|
.onResponse([this](QByteArray result)
|
||||||
{
|
{
|
||||||
auto json = QJsonDocument::fromJson(result).array();
|
auto json = QJsonDocument::fromJson(result).array();
|
||||||
if (json.empty())
|
if (json.empty())
|
||||||
{
|
{
|
||||||
@@ -711,20 +727,24 @@ void Widget::searchApp(QString text)
|
|||||||
mutex.unlock();
|
mutex.unlock();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
displaySearchApp(json);
|
displaySearchApp(json); })
|
||||||
})
|
.onError([this](QString errorStr)
|
||||||
.onError([this](QString errorStr)
|
{
|
||||||
{
|
|
||||||
qDebug() << "请求出错:" << errorStr;
|
qDebug() << "请求出错:" << errorStr;
|
||||||
sendNotification(QString(tr("Request Error: %1")).arg(errorStr));
|
sendNotification(QString(tr("Request Error: %1")).arg(errorStr));
|
||||||
mutex.unlock();
|
mutex.unlock();
|
||||||
return;
|
return; })
|
||||||
})
|
.timeout(10 * 1000)
|
||||||
.timeout(10 * 1000)
|
.exec();
|
||||||
.exec();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Widget::closeEvent(QCloseEvent *event)
|
||||||
|
{
|
||||||
|
mutex.unlock();
|
||||||
|
httpClient->deleteLater();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief 展示搜索的APP信息
|
* @brief 展示搜索的APP信息
|
||||||
*/
|
*/
|
||||||
@@ -1108,11 +1128,11 @@ void Widget::on_pushButton_uninstall_clicked()
|
|||||||
|
|
||||||
QProcess uninstall;
|
QProcess uninstall;
|
||||||
uninstall.start("pkexec", QStringList() << "apt" << "purge" << "-y" << pkgName.toLower());
|
uninstall.start("pkexec", QStringList() << "apt" << "purge" << "-y" << pkgName.toLower());
|
||||||
uninstall.waitForFinished();
|
uninstall.waitForFinished(-1); // 默认无限时长
|
||||||
|
|
||||||
QProcess check;
|
QProcess check;
|
||||||
check.start("dpkg", QStringList() << "-s" << pkgName.toLower());
|
check.start("dpkg", QStringList() << "-s" << pkgName.toLower());
|
||||||
check.waitForFinished();
|
check.waitForFinished(180); // 默认超时 3 分钟
|
||||||
|
|
||||||
if (check.readAllStandardOutput().isEmpty())
|
if (check.readAllStandardOutput().isEmpty())
|
||||||
{
|
{
|
||||||
@@ -1148,6 +1168,16 @@ void Widget::on_pushButton_clear_clicked() // 清空临时缓存目录
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Widget::on_pushButton_clearWebCache_clicked()
|
||||||
|
{
|
||||||
|
QtConcurrent::run([=]()
|
||||||
|
{
|
||||||
|
|
||||||
|
QString dataLocal = QStandardPaths::writableLocation(QStandardPaths::AppLocalDataLocation);
|
||||||
|
QDir cacheDir(dataLocal );
|
||||||
|
cacheDir.removeRecursively(); });
|
||||||
|
}
|
||||||
|
|
||||||
quint64 Widget::dirFileSize(const QString &path)
|
quint64 Widget::dirFileSize(const QString &path)
|
||||||
{
|
{
|
||||||
QDir dir(path);
|
QDir dir(path);
|
||||||
|
|||||||
@@ -91,6 +91,7 @@ private slots:
|
|||||||
void on_pushButton_updateApt_clicked();
|
void on_pushButton_updateApt_clicked();
|
||||||
void on_pushButton_uninstall_clicked();
|
void on_pushButton_uninstall_clicked();
|
||||||
void on_pushButton_clear_clicked();
|
void on_pushButton_clear_clicked();
|
||||||
|
void on_pushButton_clearWebCache_clicked();
|
||||||
void on_pushButton_website_clicked();
|
void on_pushButton_website_clicked();
|
||||||
void on_pushButton_clicked();
|
void on_pushButton_clicked();
|
||||||
void on_btn_openDir_clicked();
|
void on_btn_openDir_clicked();
|
||||||
@@ -127,6 +128,7 @@ private:
|
|||||||
void setfoot(int);
|
void setfoot(int);
|
||||||
void updatefoot();
|
void updatefoot();
|
||||||
void updateUI();
|
void updateUI();
|
||||||
|
void closeEvent(QCloseEvent *event);
|
||||||
|
|
||||||
quint64 dirFileSize(const QString &path);
|
quint64 dirFileSize(const QString &path);
|
||||||
|
|
||||||
|
|||||||
@@ -345,7 +345,7 @@
|
|||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>2</number>
|
<number>3</number>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="page">
|
<widget class="QWidget" name="page">
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||||
@@ -489,7 +489,7 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>903</width>
|
<width>889</width>
|
||||||
<height>849</height>
|
<height>849</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
@@ -993,8 +993,8 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>869</width>
|
<width>851</width>
|
||||||
<height>325</height>
|
<height>324</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||||
@@ -1123,8 +1123,8 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>738</width>
|
<width>889</width>
|
||||||
<height>886</height>
|
<height>716</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_23">
|
<layout class="QVBoxLayout" name="verticalLayout_23">
|
||||||
@@ -1285,7 +1285,31 @@
|
|||||||
<item>
|
<item>
|
||||||
<widget class="QWidget" name="widget_10" native="true">
|
<widget class="QWidget" name="widget_10" native="true">
|
||||||
<layout class="QGridLayout" name="gridLayout_4">
|
<layout class="QGridLayout" name="gridLayout_4">
|
||||||
<item row="0" column="3">
|
<item row="2" column="0" colspan="5">
|
||||||
|
<widget class="QLabel" name="label_12">
|
||||||
|
<property name="styleSheet">
|
||||||
|
<string notr="true">color:#808080</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Since the dictionary is at /tmp,It would be cleaned automatically when system reboot.</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="1">
|
||||||
|
<widget class="QLabel" name="tmp_size_ui">
|
||||||
|
<property name="text">
|
||||||
|
<string>0B</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0" colspan="2">
|
||||||
|
<widget class="QLabel" name="label_11">
|
||||||
|
<property name="text">
|
||||||
|
<string>Location:/tmp/spark-store</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="4">
|
||||||
<spacer name="horizontalSpacer_5">
|
<spacer name="horizontalSpacer_5">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
@@ -1305,16 +1329,6 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0" colspan="4">
|
|
||||||
<widget class="QLabel" name="label_12">
|
|
||||||
<property name="styleSheet">
|
|
||||||
<string notr="true">color:#808080</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Since the dictionary is at /tmp,It would be cleaned automatically when system reboot.</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
<item row="1" column="0">
|
||||||
<widget class="QLabel" name="label_13">
|
<widget class="QLabel" name="label_13">
|
||||||
<property name="maximumSize">
|
<property name="maximumSize">
|
||||||
@@ -1328,17 +1342,10 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1">
|
<item row="0" column="3">
|
||||||
<widget class="QLabel" name="tmp_size_ui">
|
<widget class="QPushButton" name="pushButton_clearWebCache">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>0B</string>
|
<string>Clear Web Cache</string>
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="0" colspan="2">
|
|
||||||
<widget class="QLabel" name="label_11">
|
|
||||||
<property name="text">
|
|
||||||
<string>Location:/tmp/spark-store</string>
|
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
@@ -92,7 +92,7 @@ void SpkAppInfoLoaderThread::run()
|
|||||||
QProcess isInstall;
|
QProcess isInstall;
|
||||||
packagename = json["Pkgname"].toString();
|
packagename = json["Pkgname"].toString();
|
||||||
isInstall.start("dpkg -s " + json["Pkgname"].toString());
|
isInstall.start("dpkg -s " + json["Pkgname"].toString());
|
||||||
isInstall.waitForFinished();
|
isInstall.waitForFinished(180); // 默认超时 3 分钟
|
||||||
int error = QString::fromStdString(isInstall.readAllStandardError().toStdString()).length();
|
int error = QString::fromStdString(isInstall.readAllStandardError().toStdString()).length();
|
||||||
if(error == 0)
|
if(error == 0)
|
||||||
{
|
{
|
||||||
@@ -100,12 +100,12 @@ void SpkAppInfoLoaderThread::run()
|
|||||||
|
|
||||||
QProcess isUpdate;
|
QProcess isUpdate;
|
||||||
isUpdate.start("dpkg-query --showformat='${Version}' --show " + json["Pkgname"].toString());
|
isUpdate.start("dpkg-query --showformat='${Version}' --show " + json["Pkgname"].toString());
|
||||||
isUpdate.waitForFinished();
|
isUpdate.waitForFinished(180); // 默认超时 3 分钟
|
||||||
QString localVersion = isUpdate.readAllStandardOutput();
|
QString localVersion = isUpdate.readAllStandardOutput();
|
||||||
localVersion.replace("'", "");
|
localVersion.replace("'", "");
|
||||||
|
|
||||||
isUpdate.start("dpkg --compare-versions " + localVersion + " ge " + json["Version"].toString());
|
isUpdate.start("dpkg --compare-versions " + localVersion + " ge " + json["Version"].toString());
|
||||||
isUpdate.waitForFinished();
|
isUpdate.waitForFinished(180); // 默认超时 3 分钟
|
||||||
if(!isUpdate.exitCode())
|
if(!isUpdate.exitCode())
|
||||||
{
|
{
|
||||||
isUpdated = true;
|
isUpdated = true;
|
||||||
|
|||||||
@@ -14,6 +14,17 @@
|
|||||||
_APTMGR=apt
|
_APTMGR=apt
|
||||||
|
|
||||||
|
|
||||||
|
####
|
||||||
|
#
|
||||||
|
# UOS sources auth config
|
||||||
|
#
|
||||||
|
#
|
||||||
|
if grep -Eqi "UnionTech" /etc/issue || grep -Eq "UnionTech" /etc/*-release;then
|
||||||
|
AUTH_UOS_USER="uos-https://license.chinauos.com-apt"
|
||||||
|
AUTH_UOS_PASSWD="`cat /etc/apt/auth.conf.d/uos.conf | grep home-packages.chinauos.com`"
|
||||||
|
AUTH_UOS_PASSWD=`echo ${AUTH_UOS_PASSWD#*password }`
|
||||||
|
|
||||||
|
fi
|
||||||
# Enable DOWNLOADBEFORE to suppress apt-fast confirmation dialog and download
|
# Enable DOWNLOADBEFORE to suppress apt-fast confirmation dialog and download
|
||||||
# packages directly.
|
# packages directly.
|
||||||
#
|
#
|
||||||
@@ -54,7 +65,7 @@ DOWNLOADBEFORE=true
|
|||||||
#
|
#
|
||||||
# Default: disabled
|
# Default: disabled
|
||||||
#
|
#
|
||||||
MIRRORS=( 'https://d.store.deepinos.org.cn/,https://d1.store.deepinos.org.cn/,https://d2.store.deepinos.org.cn/,https://d3.store.deepinos.org.cn/,https://d4.store.deepinos.org.cn/,https://d5.store.deepinos.org.cn/,http://cdn.dl.uniartisan.com:9000/deepinos/' )
|
MIRRORS=( 'https://d.store.deepinos.org.cn/,https://mirrors.sdu.edu.cn/spark-store-repository/,http://cdn.dl.uniartisan.com:9000/deepinos/,https://d1.store.deepinos.org.cn/,https://d2.store.deepinos.org.cn/,https://d4.store.deepinos.org.cn/,https://d5.store.deepinos.org.cn/' )
|
||||||
|
|
||||||
|
|
||||||
# Maximum number of connections
|
# Maximum number of connections
|
||||||
@@ -68,14 +79,10 @@ _MAXNUM=5
|
|||||||
# Maximum number of connections per server
|
# Maximum number of connections per server
|
||||||
# Default: 10
|
# Default: 10
|
||||||
#
|
#
|
||||||
_MAXCONPERSRV=10
|
_MAXCONPERSRV=1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Download file using given number of connections
|
|
||||||
# If more than N URIs are given, first N URIs are used and remaining URIs are used for backup.
|
|
||||||
# If less than N URIs are given, those URIs are used more than once so that N connections total are made simultaneously.
|
|
||||||
#
|
|
||||||
_SPLITCON=8
|
|
||||||
|
|
||||||
|
|
||||||
# Split size i.e. size of each piece
|
# Split size i.e. size of each piece
|
||||||
@@ -93,6 +100,7 @@ _MINSPLITSZ=1M
|
|||||||
_PIECEALGO=default
|
_PIECEALGO=default
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Downloadmanager listfile
|
# Downloadmanager listfile
|
||||||
# You can use this value in _DOWNLOADER command. Escape with ${}: ${DLLIST}
|
# You can use this value in _DOWNLOADER command. Escape with ${}: ${DLLIST}
|
||||||
#
|
#
|
||||||
@@ -118,7 +126,7 @@ DLLIST='/tmp/apt-fast.list'
|
|||||||
#
|
#
|
||||||
# Default: _DOWNLOADER='aria2c --no-conf -c -j ${_MAXNUM} -x ${_MAXCONPERSRV} -s ${_SPLITCON} --min-split-size=${_MINSPLITSZ} --stream-piece-selector=${_PIECEALGO} -i ${DLLIST} --connect-timeout=600 --timeout=600 -m0'
|
# Default: _DOWNLOADER='aria2c --no-conf -c -j ${_MAXNUM} -x ${_MAXCONPERSRV} -s ${_SPLITCON} --min-split-size=${_MINSPLITSZ} --stream-piece-selector=${_PIECEALGO} -i ${DLLIST} --connect-timeout=600 --timeout=600 -m0'
|
||||||
#
|
#
|
||||||
_DOWNLOADER='aria2c --no-conf -c -j ${_MAXNUM} -x ${_MAXCONPERSRV} -s ${_SPLITCON} --min-split-size=${_MINSPLITSZ} --stream-piece-selector=${_PIECEALGO} -i ${DLLIST} --connect-timeout=600 --timeout=600 -m0'
|
_DOWNLOADER='aria2c --no-conf -c -j ${_MAXNUM} -x ${_MAXCONPERSRV} --min-split-size=${_MINSPLITSZ} --stream-piece-selector=${_PIECEALGO} -i ${DLLIST} --connect-timeout=600 --timeout=600 -m0 --http-user ${AUTH_UOS_USER} --http-passwd ${AUTH_UOS_PASSWD}'
|
||||||
|
|
||||||
|
|
||||||
# Download temp folder for Downloadmanager
|
# Download temp folder for Downloadmanager
|
||||||
|
|||||||
42
tool/aptss
42
tool/aptss
@@ -1,11 +1,5 @@
|
|||||||
#/bin/bash
|
#/bin/bash
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if [ "$1" = "install" ] || [ "$1" = "upgrade" ] || [ "$1" = "full-upgrade" ] || [ "$1" = "download" ] ; then
|
|
||||||
|
|
||||||
if [ ! -e "/tmp/aptss-conf/apt-fast.conf" ];then
|
if [ ! -e "/tmp/aptss-conf/apt-fast.conf" ];then
|
||||||
###刷新apt-fast配置
|
###刷新apt-fast配置
|
||||||
mkdir -p /tmp/aptss-conf/
|
mkdir -p /tmp/aptss-conf/
|
||||||
@@ -17,10 +11,35 @@ chmod -R 755 /tmp/aptss-conf
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if [ "$1" = "install" ] || [ "$1" = "upgrade" ] || [ "$1" = "full-upgrade" ] ; then
|
||||||
|
|
||||||
DEPEND=`which apt-fast`
|
DEPEND=`which apt-fast`
|
||||||
if [ "$DEPEND" = "" ] ; then
|
if [ "$DEPEND" = "" ] ; then
|
||||||
echo "未安装依赖:apt-fast 开始安装"
|
echo "未安装依赖:apt-fast 开始安装"
|
||||||
sudo aptss ssupdate && sudo bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install apt-fast -y
|
aptss ssupdate && bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install apt-fast -y
|
||||||
|
fi
|
||||||
|
|
||||||
|
sudo bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt update -o Dir::Etc::sourcelist="sources.list.d/sparkstore.list" -o Dir::etc::sourceparts="-" -o APT::Get::List-Cleanup="0"
|
||||||
|
|
||||||
|
###执行
|
||||||
|
bwrap --dev-bind / / \
|
||||||
|
--bind '/tmp/aptss-conf/apt-fast.conf' /etc/apt-fast.conf \
|
||||||
|
--bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list \
|
||||||
|
apt-fast "$@" --allow-downgrades
|
||||||
|
|
||||||
|
|
||||||
|
elif [ "$1" = "download" ];then
|
||||||
|
DEPEND=`which apt-fast`
|
||||||
|
if [ "$DEPEND" = "" ] ; then
|
||||||
|
echo "未安装依赖:apt-fast 开始安装"
|
||||||
|
aptss ssupdate && bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install apt-fast -y
|
||||||
fi
|
fi
|
||||||
|
|
||||||
###执行
|
###执行
|
||||||
@@ -30,6 +49,15 @@ bwrap --dev-bind / / \
|
|||||||
apt-fast "$@" --allow-downgrades
|
apt-fast "$@" --allow-downgrades
|
||||||
|
|
||||||
|
|
||||||
|
elif [ "$1" = "policy" ] || [ "$1" = "search" ];then
|
||||||
|
sudo bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt update -o Dir::Etc::sourcelist="sources.list.d/sparkstore.list" -o Dir::etc::sourceparts="-" -o APT::Get::List-Cleanup="0"
|
||||||
|
|
||||||
|
###执行
|
||||||
|
bwrap --dev-bind / / \
|
||||||
|
--bind '/tmp/aptss-conf/apt-fast.conf' /etc/apt-fast.conf \
|
||||||
|
--bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list \
|
||||||
|
apt "$@" --allow-downgrades
|
||||||
|
|
||||||
elif [ "$1" = "ssupdate" ];then
|
elif [ "$1" = "ssupdate" ];then
|
||||||
|
|
||||||
mkdir -p /tmp/aptss-conf/
|
mkdir -p /tmp/aptss-conf/
|
||||||
|
|||||||
@@ -40,8 +40,6 @@ fi
|
|||||||
|
|
||||||
##################apt-fast/metalink测试
|
##################apt-fast/metalink测试
|
||||||
DEPEND="这里一定会安装所以放弃处理"
|
DEPEND="这里一定会安装所以放弃处理"
|
||||||
isuos=`cat /etc/os-release | grep UnionTech`
|
|
||||||
|
|
||||||
|
|
||||||
##############判断是否是root运行,如果是,则正常走;如果不是,则代输密码
|
##############判断是否是root运行,如果是,则正常走;如果不是,则代输密码
|
||||||
if [ "$(id -u)" != "0" ];then
|
if [ "$(id -u)" != "0" ];then
|
||||||
@@ -54,18 +52,11 @@ echo "$upass" | sudo -S aptss ssupdate && echo "$upass" | sudo -S bwrap --dev-bi
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$DEPEND" != "" ] && [ "$isuos" != "" ]; then
|
|
||||||
echo "UOS中系统依赖无法使用第三方下载工具,放弃使用apt-fast"
|
|
||||||
echo ----------------------------------------------------------------------------------
|
|
||||||
echo "$upass" | sudo -S dpkg -i $1 || sudo aptss ssupdate && sudo bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install -yf
|
|
||||||
|
|
||||||
|
if [ "$DEPEND" != "" ]; then
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$DEPEND" != "" ] && [ "$isuos" = "" ]; then
|
|
||||||
echo "检测到apt-fast,使用aptss进行多线程下载加速"
|
echo "检测到apt-fast,使用aptss进行多线程下载加速"
|
||||||
echo ----------------------------------------------------------------------------------
|
echo ----------------------------------------------------------------------------------
|
||||||
echo "$upass" | sudo -S dpkg -i $1 || sudo aptss ssupdate && sudo aptss install -yf
|
echo "$upass" | sudo -S dpkg -i $1 || sudo aptss install -yf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
@@ -81,16 +72,11 @@ echo "未安装依赖:apt-fast 开始安装"
|
|||||||
aptss ssupdate && bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install apt-fast -y
|
aptss ssupdate && bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install apt-fast -y
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$DEPEND" != "" ] && [ "$isuos" != "" ]; then
|
|
||||||
echo "UOS中系统依赖无法使用第三方下载工具,放弃使用apt-fast"
|
|
||||||
echo ----------------------------------------------------------------------------------
|
|
||||||
dpkg -i $1 || aptss ssupdate && sudo bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install -yf
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$DEPEND" != "" ] && [ "$isuos" = "" ]; then
|
if [ "$DEPEND" != "" ]; then
|
||||||
echo "检测到apt-fast,使用aptss进行多线程下载加速"
|
echo "检测到apt-fast,使用aptss进行多线程下载加速"
|
||||||
echo ----------------------------------------------------------------------------------
|
echo ----------------------------------------------------------------------------------
|
||||||
dpkg -i $1 || aptss ssupdate && aptss install -yf
|
dpkg -i $1 || aptss install -yf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -8,33 +8,6 @@ echo "获取更新列表..."
|
|||||||
PKG_LIST="$(bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt list --upgradable -o Dir::Etc::sourcelist="sources.list.d/sparkstore.list" -o Dir::Etc::sourceparts="-" -o APT::Get::List-Cleanup="0" | awk 'BEGIN {FS="/"} {print $1}' | awk NR\>1)"
|
PKG_LIST="$(bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt list --upgradable -o Dir::Etc::sourcelist="sources.list.d/sparkstore.list" -o Dir::Etc::sourceparts="-" -o APT::Get::List-Cleanup="0" | awk 'BEGIN {FS="/"} {print $1}' | awk NR\>1)"
|
||||||
|
|
||||||
|
|
||||||
isuos=`cat /etc/os-release | grep UnionTech`
|
|
||||||
if [ "$isuos" != "" ]; then ###这是确定是否为UOS 如果是
|
|
||||||
echo "UOS中系统依赖无法使用第三方下载工具,使用apt-fast下载本体"
|
|
||||||
|
|
||||||
cd /var/cache/apt/archives
|
|
||||||
for PKG_NAME in $PKG_LIST;
|
|
||||||
do
|
|
||||||
echo "$PKG_NAME 正在下载..."
|
|
||||||
sudo aptss download "$PKG_NAME" -y >/dev/null 2>&1;
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "----开始安装"
|
|
||||||
for PKG_NAME in $PKG_LIST;
|
|
||||||
do
|
|
||||||
echo "$PKG_NAME 正在更新..."
|
|
||||||
if sudo bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt install "$PKG_NAME" -y >/dev/null 2>&1;
|
|
||||||
then
|
|
||||||
echo "$PKG_NAME 已更新"
|
|
||||||
else
|
|
||||||
echo "WARNING: $PKG_NAME 无法更新"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
else ###这是确定是否为UOS,如果不是
|
|
||||||
|
|
||||||
for PKG_NAME in $PKG_LIST;
|
for PKG_NAME in $PKG_LIST;
|
||||||
do
|
do
|
||||||
echo "$PKG_NAME 正在更新..."
|
echo "$PKG_NAME 正在更新..."
|
||||||
@@ -47,6 +20,5 @@ else ###这是确定是否为UOS,如果不是
|
|||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
fi ###这是确定是否为UOS
|
|
||||||
|
|
||||||
fi ###这是确定是否同意
|
fi ###这是确定是否同意
|
||||||
Reference in New Issue
Block a user