Pages: Welcome | Projects

Unicode Symbol

2016/4/21
Tags: [ GNU/Linux ] [ perl ] [ unicode ]

A simple Perl script for your Unicode symbols:

#!/bin/perl

use warnings;
use utf8;
use strict;
use v5.16;

use charnames qw(:full);
use File::Basename;

binmode(STDOUT, ':utf8');
use feature 'say';

$0 = basename $0;
@ARGV or do {
    say STDERR "Usage $0 <symbol name>";
    say STDERR "Example: $0 GREEK CAPITAL LETTER SIGMA";
    exit 1;
};

say chr charnames::vianame("@ARGV");

It is easy to have symbols on your terminal emulator. As easy as installing a symbol font like this:

https://fedoraproject.org/wiki/Gdouros_Symbola