Monday, April 29, 2024
29
rated 0 times [  29] [ 0]  / answers: 1 / hits: 207299  / 3 Years ago, fri, may 21, 2021, 10:07:23

Is there any scripts for downloading and installing IntelliJ with JavaJDK or OpenJDK?



I don't know how I did it before using Ubuntu 12.10 but I'm now on a fresh 13.04 install and I have been looking around for an all in one script, or some scripts I can cobble together



I have the two links detailed that I think will be handy, can anyone else add to this please?



How do I install Oracle Java JDK 7?



Install Oracle Java 7 in Ubuntu via PPA Repository



Update: I have now found you can install IntelliJ through the Ubuntu software centre, so although this was a nice learning exercise for me it's not really relevant any more. Thanks to everyone that contributed.


More From » software-installation

 Answers
5

This should get you started:



#!/bin/sh

add-apt-repository ppa:webupd8team/java &&
apt-get update &&
apt-get install oracle-java7-installer &&
echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | sudo /usr/bin/debconf-set-selections &&
update-java-alternatives -s java-7-oracle &&

wget -O /tmp/intellij.tar.gz http://download.jetbrains.com/idea/ideaIC-12.0.4.tar.gz &&
tar xfz /tmp/intellij.tar.gz &&
cd idea-IC-123.169/bin &&
./idea.sh


Some things you should consider:




  • I'm not sure at which part the echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | sudo /usr/bin/debconf-set-selections has to be. Might be a line earlier.

  • The line cd idea-IC-123.169/bin is dependend on the IntelliJ version, as the extracted folder is named in that way. It only works with the version available while I'm writing this.

  • Same goes for the download link. It might change with a newer version.

  • I'm not sure what happens if you try to add a ppa that already exists again. This could lead to problems.

  • You have to execute the script as root


[#32038] Sunday, May 23, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
ardingiba

Total Points: 497
Total Questions: 95
Total Answers: 109

Location: Gabon
Member since Sat, Jan 15, 2022
2 Years ago
;