]> git.donarmstrong.com Git - neurodebian.git/commitdiff
Refactor setup instructions and create per package install instructions page.
authorMichael Hanke <michael.hanke@gmail.com>
Mon, 31 Dec 2012 09:53:10 +0000 (10:53 +0100)
committerMichael Hanke <michael.hanke@gmail.com>
Mon, 31 Dec 2012 09:53:10 +0000 (10:53 +0100)
sphinx/index.rst
sphinx/install_pkg.rst [new file with mode: 0644]
sphinx/reposetup.rst [new file with mode: 0644]

index 55494d264a6cfbf0458c238ede447ef9497454af..ed4a6c4650eb52192d9c269d49b946534b308650 100644 (file)
@@ -43,120 +43,7 @@ Learn more about NeuroDebian, the goals of this project, and help us |spread|!
 Get NeuroDebian
 ===============
 
-First select what kind of operating system you are using, and then choose a
-download server close to you:
-
-.. include:: sources_lists
-
-.. raw:: html
-
-  <div class="nojavascriptinstructions">
-  This form requires javascript. If disabled, incomplete instructions are
-  displayed below</div>
-  <div id="repoconfig">
-  <div class="nojavascriptinstructions">
-  Instructions for Debian-derived systems
-  </div>
-  <p>Select desired components:<br />
-  <table><tr>
-  <td><input type="radio" name="components" value="libre"></td>
-  <td><strong>only</strong> software with guaranteed freedoms<br />
-    <span style=font-size:75%>all packages are
-    <a href="http://www.debian.org/social_contract#guidelines">DSFG</a>-compliant,
-    with permission to use, modify, re-distribute under any condition</span></td></tr>
-  <tr><td><input type="radio" name="components" value="full"></td>
-  <td>all software<br />
-    <span style=font-size:75%>
-    individual packages may have restrictive licenses and you are required to
-    check license-compliance manually
-    </span></td></tr>
-  </table>
-  <div id="reposetup">
-
-You can enable NeuroDebian on your system by simply copying and pasting the
-following two commands into a terminal window. This will add the NeuroDebian
-repository to your native package management system, and you will be able to
-install neuroscience software the same way as any other package.
-
-.. raw:: html
-
-  <pre id="code">
-  After selecting a release the setup code will be shown here.
-  </pre>
-
-Now you can update the package index and you are ready to install packages.
-Of course you can use your favorite package manager (e.g. synaptic, adept)
-for this. In the terminal you can use :command:`apt-get`::
-
-  sudo apt-get update
-  sudo apt-get install mricron
-
-You are ready to go -- enjoy NeuroDebian!
-
-.. note::
-
-  Not every package is available for all distributions/releases. For information
-  about which package version is available for which release and architecture,
-  please have a look at the corresponding package pages.
-
-.. raw:: html
-
-  </div> <!-- end reposetup -->
-  </div> <!-- end repoconfig -->
-
-  <div id="vmsetup">
-  <div class="nojavascriptinstructions">
-  Instructions for non-Debian systems
-  </div>
-
-For all non-Debian operating systems we recommend to deploy NeuroDebian as a
-`virtual appliance`_ (virtual machine) -- this will only take a few minutes.
-On all modern hardware (built within
-the last 3-4 years) a virtual appliance is a convenient solution to run
-NeuroDebian simultaneously with the primary operating system -- without
-noticeable performance loss. To start using NeuroDebian:
-
-1. Download this image file:
-
-.. raw:: html
-
-  <div id="vmimagedownload">
-  <a href="http://neuro.debian.net/debian/vm/">NeuroDebian images</a>
-  </div>
-
-2. Import this image into VirtualBox_. If you do not have VirtualBox_
-   installed yet, visit the `VirtualBox download page
-   <http://www.virtualbox.org/wiki/Downloads>`_ and get an installer for your
-   system (installers for Windows, Linux, Mac and Solaris are available).
-
-3. Finish the configuration by following :ref:`the instructions on setting up
-   the virtual appliance <chap_vm>`. `[Virtual machine
-   setup video tutorial] <http://www.youtube.com/watch?v=eqfjKV5XaTE>`_
-
-
-
-
-You are ready to go -- enjoy NeuroDebian!
-
-.. note::
-
-  If you still running an older VirtualBox 3.x, download one of the image files
-  listed below. These older releases are distributed as a `zip` file. Please
-  extract all files from the `.zip` file, using appropriate software
-  for your operating system.
-
-  * `NeuroDebian 6.0.2 image (32bit)
-    <http://neuro.debian.net/debian/vm/neurodebian_6.0.2_i386.zip>`_ [~545MB]
-
-  * `NeuroDebian 6.0.2 image (64bit)
-    <http://neuro.debian.net/debian/vm/neurodebian_6.0.2_amd64.zip>`_ [~560MB]
-
-.. raw:: html
-
-  </div> <!-- end vmsetup -->
-
-.. _virtual appliance: http://en.wikipedia.org/wiki/Virtual_appliance
-.. _VirtualBox: http://www.virtualbox.org
+.. include:: reposetup.rst
 
 .. _news:
 
@@ -301,77 +188,4 @@ News
       $(buttonid).html("&darr;&darr;&darr;");
   };
 
-  function createvmdownload(rel, mir) {
-        var img_version = '6.0.5';
-        var img_suffix;
-        var base_url;
-        var img_url;
-        var md5sum_url;
-        if (rel == 'win32') {
-            img_suffix = 'i386';
-        } else {
-            img_suffix = 'amd64';
-        };
-        if(mir in mirrors) {
-            base_url = mirrors[mir] + '/vm/';
-            img_url = base_url + 'NeuroDebian_' + img_version + '_' + img_suffix + '.ova';
-            md5sum_url = base_url + 'MD5SUMS';
-        } else {
-            return 'Internal error';
-        };
-        return '<blockquote><a href="' + img_url
-               + '">Virtual applicance image</a> [<a title="Verify image integrity by dowloading this file and running `md5sum -c MD5SUMS`" href="'
-               + md5sum_url
-               + '">MD5SUM</a>, <a title="Verify authenticity of the MD5SUM file by downloading this file and running `gpg –verify MD5SUMS.gpg`" href="'
-               + md5sum_url + '.gpg">MD5SUM.gpg</a>]</blockquote>' ;
-
-  };
-
-  function createrepourl(rel, mir, comp) {
-    if(mir in mirrors) {
-        var retrepo = "wget -O- http://neuro.debian.net/lists/" + rel + "."
-         + mir + "." + comp + " | sudo tee /etc/apt/sources.list.d/neurodebian.sources.list\n"
-         + "sudo apt-key adv --recv-keys --keyserver pgp.mit.edu 2649A5A9\n";
-        return retrepo;
-    }
-
-  };
-
-  function update_by_form() {
-     var rel = $("#release").val();
-     var mir = $("#mirror").val();
-     var comp = $('input[name="components"]:checked').val();
-     if (rel != '' && mir != '') {
-        if (rel in {'win32':'', 'win64':'', 'mac':''}) {
-            $('#vmimagedownload').html(createvmdownload(rel, mir));
-            $('#vmsetup').slideDown();
-            $('#repoconfig').slideUp();
-        } else {
-            $('#vmsetup').slideUp();
-            $('#repoconfig').slideDown();
-            if (comp == undefined) {
-              $('#reposetup').slideUp();
-            } else {
-              $('#code').text(createrepourl(rel, mir, comp));
-              $('#reposetup').slideDown();
-            }
-        };
-     }
-     else
-     {
-        $('#repoconfig').slideUp();
-        $('#vmsetup').slideUp();
-     };
-  };
-
-  $(document).ready(function($) {
-     update_by_form();
-     $('#repoconfig').hide()
-     $('#reposetup').hide();
-     $('#vmsetup').hide()
-     $('#release').change(update_by_form);
-     $('#mirror').change(update_by_form);
-     $('input[name=components]:radio').change(update_by_form);
-  });
-
   </script>
diff --git a/sphinx/install_pkg.rst b/sphinx/install_pkg.rst
new file mode 100644 (file)
index 0000000..699b961
--- /dev/null
@@ -0,0 +1,26 @@
+Install a package
+=================
+
+Step 1
+------
+
+*[skip this steps if your machine is already configured to use this repository]*
+
+.. include:: reposetup.rst
+
+Step 2
+------
+
+To install the ``###pkgname###`` package on your system or virtual machine,
+open a terminal and execute the following command::
+
+  sudo apt-get install ###pkgname###
+
+.. raw:: html
+
+  <script type="text/javascript">
+    var split = location.search.replace('?', '').split('=')
+    if ( split[0] == 'p' ) {
+      $(document.body).html($(document.body).html().replace('###pkgname###', split[1]));
+    }
+  </script>
diff --git a/sphinx/reposetup.rst b/sphinx/reposetup.rst
new file mode 100644 (file)
index 0000000..f4ebaa5
--- /dev/null
@@ -0,0 +1,190 @@
+First select what kind of operating system you are using, and then choose a
+download server close to you:
+
+.. include:: sources_lists
+
+.. raw:: html
+
+  <div class="nojavascriptinstructions">
+  This form requires javascript. If disabled, incomplete instructions are
+  displayed below</div>
+  <div id="repoconfig">
+  <div class="nojavascriptinstructions">
+  Instructions for Debian-derived systems
+  </div>
+  <p>Select desired components:<br />
+  <table><tr>
+  <td><input type="radio" name="components" value="libre"></td>
+  <td><strong>only</strong> software with guaranteed freedoms<br />
+    <span style=font-size:75%>all packages are
+    <a href="http://www.debian.org/social_contract#guidelines">DSFG</a>-compliant,
+    with permission to use, modify, re-distribute under any condition</span></td></tr>
+  <tr><td><input type="radio" name="components" value="full"></td>
+  <td>all software<br />
+    <span style=font-size:75%>
+    individual packages may have restrictive licenses and you are required to
+    check license-compliance manually
+    </span></td></tr>
+  </table>
+  <div class="reposetup">
+
+You can enable NeuroDebian on your system by simply copying and pasting the
+following two commands into a terminal window. This will add the NeuroDebian
+repository to your native package management system, and you will be able to
+install neuroscience software the same way as any other package.
+
+.. raw:: html
+
+  <pre id="code">
+  After selecting a release the setup code will be shown here.
+  </pre>
+
+Now you can update the package index and you are ready to install packages.
+Simply execute the following command in a terminal::
+
+  sudo apt-get update
+
+You are ready to go -- enjoy NeuroDebian!
+
+.. note::
+
+  Not every package is available for all distributions/releases. For information
+  about which package version is available for which release and architecture,
+  please have a look at the corresponding package pages.
+
+.. raw:: html
+
+  </div> <!-- end reposetup -->
+  </div> <!-- end repoconfig -->
+
+  <div id="vmsetup">
+  <div class="nojavascriptinstructions">
+  Instructions for non-Debian systems
+  </div>
+
+For all non-Debian operating systems we recommend to deploy NeuroDebian as a
+`virtual appliance`_ (virtual machine) -- this will only take a few minutes.
+On all modern hardware (built within
+the last 3-4 years) a virtual appliance is a convenient solution to run
+NeuroDebian simultaneously with the primary operating system -- without
+noticeable performance loss. To start using NeuroDebian:
+
+1. Download this image file:
+
+.. raw:: html
+
+  <div id="vmimagedownload">
+  <a href="http://neuro.debian.net/debian/vm/">NeuroDebian images</a>
+  </div>
+
+2. Import this image into VirtualBox_. If you do not have VirtualBox_
+   installed yet, visit the `VirtualBox download page
+   <http://www.virtualbox.org/wiki/Downloads>`_ and get an installer for your
+   system (installers for Windows, Linux, Mac and Solaris are available).
+
+3. Finish the configuration by following :ref:`the instructions on setting up
+   the virtual appliance <chap_vm>`. `[Virtual machine
+   setup video tutorial] <http://www.youtube.com/watch?v=eqfjKV5XaTE>`_
+
+
+
+
+You are ready to go -- enjoy NeuroDebian!
+
+.. note::
+
+  If you still running an older VirtualBox 3.x, download one of the image files
+  listed below. These older releases are distributed as a `zip` file. Please
+  extract all files from the `.zip` file, using appropriate software
+  for your operating system.
+
+  * `NeuroDebian 6.0.2 image (32bit)
+    <http://neuro.debian.net/debian/vm/neurodebian_6.0.2_i386.zip>`_ [~545MB]
+
+  * `NeuroDebian 6.0.2 image (64bit)
+    <http://neuro.debian.net/debian/vm/neurodebian_6.0.2_amd64.zip>`_ [~560MB]
+
+.. raw:: html
+
+  </div> <!-- end vmsetup -->
+
+.. _virtual appliance: http://en.wikipedia.org/wiki/Virtual_appliance
+.. _VirtualBox: http://www.virtualbox.org
+
+.. raw:: html
+
+  <script type="text/javascript">
+  function createvmdownload(rel, mir) {
+        var img_version = '6.0.5';
+        var img_suffix;
+        var base_url;
+        var img_url;
+        var md5sum_url;
+        if (rel == 'win32') {
+            img_suffix = 'i386';
+        } else {
+            img_suffix = 'amd64';
+        };
+        if(mir in mirrors) {
+            base_url = mirrors[mir] + '/vm/';
+            img_url = base_url + 'NeuroDebian_' + img_version + '_' + img_suffix + '.ova';
+            md5sum_url = base_url + 'MD5SUMS';
+        } else {
+            return 'Internal error';
+        };
+        return '<blockquote><a href="' + img_url
+               + '">Virtual applicance image</a> [<a title="Verify image integrity by dowloading this file and running `md5sum -c MD5SUMS`" href="'
+               + md5sum_url
+               + '">MD5SUM</a>, <a title="Verify authenticity of the MD5SUM file by downloading this file and running `gpg –verify MD5SUMS.gpg`" href="'
+               + md5sum_url + '.gpg">MD5SUM.gpg</a>]</blockquote>' ;
+
+  };
+
+  function createrepourl(rel, mir, comp) {
+    if(mir in mirrors) {
+        var retrepo = "wget -O- http://neuro.debian.net/lists/" + rel + "."
+         + mir + "." + comp + " | sudo tee /etc/apt/sources.list.d/neurodebian.sources.list\n"
+         + "sudo apt-key adv --recv-keys --keyserver pgp.mit.edu 2649A5A9\n";
+        return retrepo;
+    }
+
+  };
+
+  function update_by_form() {
+     var rel = $("#release").val();
+     var mir = $("#mirror").val();
+     var comp = $('input[name="components"]:checked').val();
+     if (rel != '' && mir != '') {
+        if (rel in {'win32':'', 'win64':'', 'mac':''}) {
+            $('#vmimagedownload').html(createvmdownload(rel, mir));
+            $('#vmsetup').slideDown();
+            $('#repoconfig').slideUp();
+        } else {
+            $('#vmsetup').slideUp();
+            $('#repoconfig').slideDown();
+            if (comp == undefined) {
+              $('.reposetup').slideUp();
+            } else {
+              $('#code').text(createrepourl(rel, mir, comp));
+              $('.reposetup').slideDown();
+            }
+        };
+     }
+     else
+     {
+        $('#repoconfig').slideUp();
+        $('#vmsetup').slideUp();
+     };
+  };
+
+  $(document).ready(function($) {
+     update_by_form();
+     $('#repoconfig').hide()
+     $('.reposetup').hide();
+     $('#vmsetup').hide()
+     $('#release').change(update_by_form);
+     $('#mirror').change(update_by_form);
+     $('input[name=components]:radio').change(update_by_form);
+  });
+
+  </script>