FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
sysadminscripts/java-install at main · matveynator/sysadminscripts · GitHub
matveynator
/
sysadminscripts
Public
Notifications
You must be signed in to change notification settings
Fork
0
Star
11
Code
Issues
0
Pull requests
0
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
sysadminscripts
/
java-install
Copy path
More file actions
More file actions
Latest commit
History
History
History
20 lines (15 loc) · 462 Bytes
Breadcrumbs
sysadminscripts
/
java-install
Copy path
File metadata and controls
20 lines (15 loc) · 462 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!
/bin/bash
path=
"
/usr/lib/jvm
"
mkdir -p
${path}
echo
"
enter java tar.gz url (get links at https://jdk.java.net/java-se-ri/7)
"
read
url
[
"
${url}
"
==
"
"
]
&&
echo
"
java url empty!
"
&&
exit
1
curl -L
${url}
>
/tmp/java.tar.gz
tar xfz /tmp/java.tar.gz -C
${path}
for
java_path
in
`
ls -d
${path}
/
*
`
;
do
for
app
in
java javac javadoc javap
;
do
update-alternatives --install /usr/bin/
${app}
${app}
${java_path}
/bin/
${app}
1
done
done
Back
|
FazBrowse Home
|
New Git URL