Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
eepm
Commits
303cb135
Commit
303cb135
authored
Aug 11, 2022
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
epm play assistant: add URI checking and fix download on Ubuntu
parent
80a958ff
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
assistant.sh
play.d/assistant.sh
+11
-2
No files found.
play.d/assistant.sh
View file @
303cb135
...
...
@@ -18,16 +18,25 @@ fi
arch
=
"
$(
$DISTRVENDOR
-a
)
"
pkg
=
"
$(
$DISTRVENDOR
-p
)
"
# some locale depend troubles (ALT with bash 4 needs LANG=ru_RU.UTF-8, Ubuntu with bash 5 needs LANG=C.UTF-8)
#URL="https://мойассистент.рф/скачать"
URL
=
"https://xn--80akicokc0aablc.xn--p1ai/%D1%81%D0%BA%D0%B0%D1%87%D0%B0%D1%82%D1%8C"
if
!
LANG
=
ru_RU.UTF8 check_url_is_accessible
"
$URL
"
;
then
epm tool eget
-O-
"
$URL
"
fatal
"Please, check why
$URL
is not accessible"
fi
# parse vendor site
tmpfile
=
$(
mktemp
)
LANG
=
ru_RU.UTF8 epm tool eget
-q
-O-
"https://мойассистент.рф/скачать
"
|
grep
-A50
"Ассистент для LINUX"
>
$tmpfile
epm tool eget
-q
-O-
"
$URL
"
|
grep
-A50
"Ассистент для LINUX"
>
$tmpfile
url_by_order
()
{
local
order
=
"
$1
"
local
pkg
=
"
$(
cat
$tmpfile
|
grep
"/Download/"
|
$order
-n1
|
sed
-e
's|.*href="||'
-e
's|".*||'
)
"
[
-n
"
$pkg
"
]
||
fatal
"Can't get Download href"
echo
"https://мойассистент.рф
$pkg
"
#echo "https://мойассистент.рф$pkg"
echo
"https://xn--80akicokc0aablc.xn--p1ai
$pkg
"
}
case
$arch
-
$pkg
in
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment