GB0DD

       -- Hey, you wanna play Voyager?
       -- It is cold and dark out there.
          Just said it.

"tr" on Linux
=============

I. Linux Mint 18 "Sarah" on Virtualbox VM (virtual machine)
-----------------------------------------------------------

  OS:          Ubuntu 64-bit
  RAM:         4096MB
  DISPLAY RAM: 128MB
  Acceleration: [v] Enable 3D Acceleration

  ISO: linuxmint-18-cinnamon-64bit.iso

Install from ISO and upgrade Cinnamon to 3.2.x [1].

II. Tuning "Sarah"
------------------

Menu -> System Settings -> Hardware -> Keyboard Layouts -> [ + ]

  English (US)
  Estonian
  Russian

[Options] -> Switching to another layout LCtrl+LShift

Create test

  $ cat utf8.c
  #include <locale.h>
  #include <stdio.h>
  #include <wchar.h>

  int main()
  {
      setlocale( LC_CTYPE, "en_US.UTF-8");
      wprintf( L"üõöäžšÜÕÖŽŠ\n");

      return 0;
  }

Compile it with

  $ gcc utf8.c -o utf8

We have

  utf8.c:1:20: fatal error: locale.h: No such file or directory
  compilation terminated.

Problem might be solved with

  # apt-get install libc6-dev

Now

  $ gcc utf8.c -o utf8
  $ ./utf8
  üõöäžšÜÕÖŽŠ

III. Building Heirloom ToolChest* on Linux Mint Sarah
----------------------------------------------------

On page http://heirloom.sourceforge.net/tools.html. Press on Follow "these instructions" for more information.. Download file

   heirloom-070715.tar.bz2

(https://sourceforge.net/projects/heirloom/files/heirloom/070715/)

   # sudo apt-get install zlib1g-dev libncurses-dev
   # make
   # mv /usr/bin/tr /usr/bin/tr.mint
   # cp /home/virtu/Downloads/heirloom-070715/tr/tr /usr/bin/tr

Script that drops the roof from umlauts and compose email address as

  name.surename@ufo.mars

  $ cat People

  $ cat People | \
    tr öäüõÖÄÜÕ oauoOAUO | \
    echo $(awk '{print $1"."$2"@ufo.mars"}') | sed 's/ /\n/g'

----------

*) Where do I buy heirloom chest plate stuff
   http://us.battle.net/forums/en/wow/topic/16201180333

Links
-----

[1] Cinnamon 3.2.1 on Linux Mint "Sarah"
    (
      add-apt-repository ppa:embrosyn/cinnamon
      apt-get update && apt-get upgrade
      ### Even if already installed ###
      apt-get install cinnamon
    )

      https://launchpad.net/~embrosyn/+archive/ubuntu/cinnamon
      http://winaero.com/blog/cinnamon-3-2-is-out/

[2] How To Map A Windows Network Drive In Linux Mint
    (in file explorer menu: File -> Connect to server.)

      http://mixeduperic.com/linux-mint
        /how-to-map-a-windows-network-drive-in-linux-mint.html

NOTE
====

To obtain baseline data, please contact the teacher.

