User:Timothee Flutre/Notebook/Postdoc/2013/12/27: Difference between revisions
From OpenWetWare
(→About organizing computer-based research: add Rlibs and PYTHONPATH) |
(→About organizing computer-based research: add link to install progs in your HOME) |
||
(4 intermediate revisions by 2 users not shown) | |||
Line 2: | Line 2: | ||
|- | |- | ||
|style="background-color: #EEE"|[[Image:owwnotebook_icon.png|128px]]<span style="font-size:22px;"> Project name</span> | |style="background-color: #EEE"|[[Image:owwnotebook_icon.png|128px]]<span style="font-size:22px;"> Project name</span> | ||
|style="background-color: #F2F2F2" align="center"| | |style="background-color: #F2F2F2" align="center"|[[File:Report.png|frameless|link={{#sub:{{FULLPAGENAME}}|0|-11}}]][[{{#sub:{{FULLPAGENAME}}|0|-11}}|Main project page]]<br />{{#if:{{#lnpreventry:{{FULLPAGENAME}}}}|[[File:Resultset_previous.png|frameless|link={{#lnpreventry:{{FULLPAGENAME}}}}]][[{{#lnpreventry:{{FULLPAGENAME}}}}{{!}}Previous entry]] }}{{#if:{{#lnnextentry:{{FULLPAGENAME}}}}|[[{{#lnnextentry:{{FULLPAGENAME}}}}{{!}}Next entry]][[File:Resultset_next.png|frameless|link={{#lnnextentry:{{FULLPAGENAME}}}}]]}} | ||
|- | |- | ||
| colspan="2"| | | colspan="2"| | ||
Line 10: | Line 10: | ||
* '''OS choice''': concerning computers, one usually has a preferred [https://en.wikipedia.org/wiki/Operating_system operating system]. Yet, in scientific projects where computing is an important aspect of research, the most frequent is [https://en.wikipedia.org/wiki/Linux GNU/Linux]. Thus, even if it's always good to know how to find our way on other operating systems, such as [https://en.wikipedia.org/wiki/Microsoft_Windows Microsoft Windows] and [https://en.wikipedia.org/wiki/OS_X Apple Mac OS X], I will focus in the following on GNU/Linux. | * '''OS choice''': concerning computers, one usually has a preferred [https://en.wikipedia.org/wiki/Operating_system operating system]. Yet, in scientific projects where computing is an important aspect of research, the most frequent is [https://en.wikipedia.org/wiki/Linux GNU/Linux]. Thus, even if it's always good to know how to find our way on other operating systems, such as [https://en.wikipedia.org/wiki/Microsoft_Windows Microsoft Windows] and [https://en.wikipedia.org/wiki/OS_X Apple Mac OS X], I will focus in the following on GNU/Linux. | ||
* '''Home''': | * '''GNU/Linux''': if you begin on this OS, check out the following links! | ||
** [http://en.flossmanuals.net/command-line/index/ tutorial] on the command-line; | |||
** [http://www.commentcamarche.net/faq/8386-kit-de-survie-linux kit] de survie Linux; | |||
** [http://www.ibm.com/developerworks/aix/library/au-unixtext/index.html lessons] on text manipulations; | |||
** [http://www.tldp.org/LDP/abs/html/ book] on advanced bash scripting. | |||
* '''Home''': see also [http://nullprogram.com/blog/2017/06/19/ here] | |||
** I create a set of directories, via <code>mkdir -p bin include lib share src src_ext src_ext/Rlibs texmf tmp work</code>: | ** I create a set of directories, via <code>mkdir -p bin include lib share src src_ext src_ext/Rlibs texmf tmp work</code>: | ||
*** <code>bin</code>: contains executables; | *** <code>bin</code>: contains executables; | ||
Line 22: | Line 28: | ||
*** <code>tmp</code>: contains temporary tasks; | *** <code>tmp</code>: contains temporary tasks; | ||
*** <code>work</code>: contains projects. | *** <code>work</code>: contains projects. | ||
** this structure is reflected in my file <code>~/.bash_profile</code>: | ** this structure is reflected in my file <code>~/.bash_profile</code> (versioned [https://github.com/timflutre/perso/blob/master/bash_profile here]): | ||
*** in my case, it's been necessary to specify [https://en.wikipedia.org/wiki/CFLAGS CFLAGS, CPPFLAGS and CXXFLAGS] | |||
*** I also have access to computer clusters and mainly use one, on which I have my own private git server: <code>mkdir -p ~/opt; mkdir -p ~/opt/git</code> | |||
</ | |||
* '''External packages''': for each external package in <code>src_ext</code>, I create a directory with its usual name, say emacs, in which I create a file <code>install.bash</code> with the necessary commands to compile and install the package, typically: | * '''External packages''': for each external package in <code>src_ext</code>, I create a directory with its usual name, say emacs, in which I create a file <code>install.bash</code> with the necessary commands to compile and install the package, typically: |
Latest revision as of 15:55, 4 November 2017
Project name | Main project page Previous entry |
About organizing computer-based research
#!/usr/bin/env bash wget http://gnu.mirrors.hoobly.com/gnu/emacs/emacs-24.3.tar.gz tar xzvf emacs-24.3.tar.gz cd emacs-24.3 ./configure --prefix=$HOME --with-x-toolkit=no --with-xpm=no --with-jpeg=no --with-gif=no --with-tiff=no make make install
#!/usr/bin/env bash # backup.bash <path_to_backup> >& backup.log & date RSYNC_OPT="--compress --recursive --times --perms --links --exclude="*~" --delete --delete-excluded --progress" rsync $RSYNC_OPT ~/remote1/work/project1 $1 rsync $RSYNC_OPT ~/remote1/work/project2 $1 date
|