Opened 11 years ago

Last modified 11 years ago

#515 new enhancement

rewrite installer

Reported by: epruesse Owned by: devel
Priority: normal Milestone:
Component: Usability Version: SVN
Keywords: Cc:

Description

The install script should:

  • display license
  • check for dependencies, install if possible, present help if not
  • ask for system wide or user install
  • ask for paths
    1. system
      • BIN=/usr/local/bin
      • ARBHOME=/opt/arb-$VERSION
      • CACHE=$ARBHOME/cache
    2. user
      • BIN=$HOME/bin
        • ask && update .bashrc/.cshrc/.profile if $BIN not in $PATH
      • ARBHOME=$HOME/arb-$VERSION
      • CACHE=NONE (we have .arb_pts)
  • check for previous install
    • if previous arb_tcp.dat != arb_tcp_orig.dat
      • ask whether to keep
      • show diff
  • copy . to $ARBHOME
  • create symlink in $BIN
  • adapt arb_tcp.dat
  • print welcome/help

Optionally: use makeself.sh to build self-extracting package.

Change History (3)

comment:1 follow-up: Changed 11 years ago by westram

Another (related?) wanna-have:

  • double-clicking on xxx.arb in system file-browser (nautilus, …) should run
    arb xxx.arb

comment:2 in reply to: ↑ 1 Changed 11 years ago by epruesse

Replying to westram:

Another (related?) wanna-have:

  • double-clicking on xxx.arb in system file-browser (nautilus, …) should run
    arb xxx.arb

For that, we need to do the following:

  1. Add a mime-type. Those are defined with small XML files. The following should work:
    <?xml version="1.0" encoding="UTF-8"?>
    <mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
       <mime-type type="application/x-arb">
         <comment>ARB database file</comment>
         <magic priority="50">
           <match value="this is the binary version of the gbtum data file version" type="string" offset="6"/>
         </magic>
         <glob pattern="*.arb"/>
       </mime-type>
    </mime-info>
    
    This file needs to be installed with xdg-mime install --no-vendor arb.xml. The no-vendor is because we should have a "vendor" name in theory. As in "sun-java".
  2. Then we need to register the application using a .desktop file, which could look like this:
    [Desktop Entry]
    Name=ARB
    Encoding=UTF-8
    Exec=arb %f
    Icon=arb
    Type=Application
    Categories=GTK;Science;Biology
    Terminal=false
    Comment=Describe ARB here
    MimeType=application/x-arb
    
    This is installed with xdg-desktop-icon install --novendor arb.desktop to the desktop and with xdg-desktop-menu install --novendor arb.desktop to the menu.
  3. The icons for the .desktop file and the mime type are installed with xdg-icon-resource install --size 128 arb.png and xdg-icon-resource install --context mimetypes --size 128 arb-128.png application-x-arb, where 128 should be 48/64/128/scaleable and the icon matching.
  4. Create ARB launcher and File-Type icons… ;-)

comment:3 Changed 11 years ago by epruesse

Hmm. While we're at it, we could register ARB as default handler for .fasta, .phylip, .gb, .embl, .tree and .newick. A bit of Perl to find the youngest running ARB and navigate to the import menu should do the trick… ;-)

Note: See TracTickets for help on using tickets.