sabato, ottobre 11, 2014

Scite and regular expression

Hi,

 I don't know if you use Scite editor (http://www.scintilla.org/SciTE.html) but I use this instead of classic Notepad.

The problem of the day (POD) is to transform a very long list of integer (1 2 3 and so on) adding an apex in prefix and suffix.

Yes yes, I know that there are a lot of solutions for do this, one may be to write an assembly program, but the challenge is to do it fast as possible. Regular expression and Scite can be a good solution. Just copy the list of number, CTRL+H (Replace function), Find: \(\d+\) and Replace: '\1', where 1 is the positional group of regular expression.

 Voilà.

 Salvo.

mercoledì, ottobre 08, 2014

How to find ram slots info in Linux

Hi,

this morning I'm looking for a software to find the slot allocation of my servers.

With google I've got a result that is nice and very helpful:

dmidecode -t memory | grep "Size:\|Set:"

Ref: http://www.linuxnix.com/2013/01/find-ram-slots-infousing-dmidecodelshw-in-linux.html
Salvo.