Nice “?vars” PDL feature


pdl.png

I’m starting with PDL – Perl Data Language manual, more precisely, PDL::Indexing manual, and I found a nice feature to view variables declared in current session of pdl2 interpreter: ?vars. This command is a shortcut to help vars and/or PDL->vars, it shows a report about all variables with name, data type, dimension, flow, state and memory used.

See an example:

pdl> ?vars
PDL variables in package main::

Name         Type   Dimension       Flow  State          Mem
----------------------------------------------------------------
$a           Double D [8,4,3,2,1]          P            1.50KB
$area        Double D [2,3]                VC           0.00KB
$column      Double D [1,5]                VC           0.00KB
$cube        Double D [5,5,5]              P            0.98KB
$even        Double D [5,2]                VC           0.00KB
$im          Double D [5,5]                P            0.20KB
$line        Double D [5]                  VC           0.00KB
$rgb         Double D [255,255,255]        P          126.51MB
$row         Double D [5,1]                VC           0.00KB
pdl> _

Variables with “VC” (Virtual Child) in the “State” column and “0.00KB” in “Mem” column are children of variables with “P” (Parent) in the “State” column. They share space and modifications will reflect on the parent variables and other children, if applicable.

Anúncios

Accessing Android from Emacs


Using tramp-adb is easy to access Android‘s filesystem and shell, but we still need the Android Debug Bridge (and all the Java configuration pain included…).

I didn’t know this Emacs‘s feature and started using it recently. For example, to access my old current phone, I plug it to USB port and hit into Emacs:

,-—
| C-x C-f /adb:
`-—

And the device is autocompleted.

Move, rename and delete files are fine with Dired and eshell is good as sh, but, for now, I don’t know how to inform eshell to use the device’s root instead the root of my laptop… I need to research more and make this a better workflow to tests and day tasks.

Migrating from Mutt to Mu4e


After ~13 years, I changed my /MUA/ from Mutt / muttng to Mu4e. The main purpose was integration with Emacs. For now, I don’t need all Mutt‘s features any more because nearly all my discussion-lists are dead more than 1 year and my e-mail is little used now. BBDB and Org Mode are some new best features in this new workflow.

Trying WebKit on Emacs


Last week, I read an article about WebKit‘s Emacs integration and I get interested in this kind of solution, surfing web inside Emacs looks like a good idea, like “What?! I don’t need go out Emacs? Good!”. I’m a “text-mode” guy, but, last years until now, I start to use more the X11 with the very handy Emacs Server & emacsclient.

More…

Evitando redigitação de senha colocando o comando su em background


Já acessou um servidor ssh com número limitado de logins e ficou o dia inteiro fazendo login e logout de contas como a do root por exemplo porque precisava retornar ao usuário comum para outros procedimentos? Pois seus problemas acabaram…

Continue lendo…

Estendendo o font-lock do perl-mode


Já faz uns anos que eu vinha descontente com o syntax highlighting padrão do perl-mode, sobretudo, porque ele não destaca os builtins do Perl. Pesquisei na web por métodos prontos para resolver o problema uma vez que combinar cores não é minha área. Infelizmente, minhas buscas sempre deram em nada.

Continue lendo…