Interesting TeX tricks
Simply a page with some interesting TeX tricks: volkerschatz.com.
Simply a page with some interesting TeX tricks: volkerschatz.com.
La propaganda de MediaMarkt que hoy acompañaba al periódico me ha sorprendido bastante. Como se puede ver en la imágen (sacada de su página web), no solo ofrecen una PDA con Linux, sino que la palabra “Linux” aparece dentro de la flechita blanca que utilizan para resaltar los “puntos fuertes” del producto.
No quiere esto decir que se hayan vuelto “buenos”, pero hasta ahora (y como todos los vendedores) han estado vendidos al Enemigo Oscuro incondicionalmente. Ya sé que si venden gadgets con Linux o lo anuncian es simplemente por marketing: es una palabra de moda y vende más. Lo que me llena de alegrÃa es precisamente que “Linux” sea una palabra que venda más y pueda ser utilizada por motivos de marketing. Eso significa que cada vez hay una base más amplia de consumidores que lo toman en cuenta, ¿no?
This YouTube video shows Compiz Fusion running on my work computer. It has a fairly decent CPU (P4 3.00GHz), but no “useless” things like sound cards or (more relevant for this issue) graphics card. The only thing it has is an Intel 82865G graphics chip integrated in the motherboard. We are talking about an integrated chip (not dedicated graphics card) released in May 2003.
Judge the performance for yourself (take into account that the actual performance is higher, since the recording program to make the video also uses up some resources):
Intro
Any GNU/Linux user ends up hearing, sooner or later, the Ultimate Argument(tm) from a Windows fanboy:
If Linux is so good, and is given away for free, how can Windows still be so prominent?
Ironically, many Windows users answer the question themselves, when explaining why they can’t make the switch to Linux:
The concept than embraces all the preceding points, and answers the rhetorical question above, is vendor lock-in. I will try to explain the concept with a humble tale I have used twice so far in comments to entries in Enrique Dans’s blog.
Tales of bicycles and cars
Imagine a country with no bicycles.
One day a guy comes up with the idea of making them, and starts to produce, and sell, bicycles that we shall call of type A. Being an empty market, the A-type bicycles quickly triumph, and the maker makes a lot of money.
But some time later, a second guy devises a better bike design (type B), and decides to produce and sell it. The price and the quality are better, so when people buy a new bike or replace an old one, they tend to buy bikes of type B. Soon enough, the market is dominated by the new, better, bicycle.
Now imagine a country with no cars.
One day a guy comes up with the idea of making cars, and starts to produce and sell cars of type A. As cars need petrol to run, A-type gas stations develop in parallel to car sales. Building gas stations is expensive, but sales are guaranteed, as everyone has or will have A-type cars, and they need A-type petrol: their growth is synergistic.
But some time later, a second guy devises a better car design (type B) and decides to produce and sell it. The price and the quality are better, BUT drivers can not buy B-type cars, because there is no B-type gas station. The problem is that, since noone has a B-type car, making B-type gas stations is doomed to bankrupt. So, no B-type cars are sold, because there are no B-type gas stations, and B-type gas stations will not be made until B-type cars are popular!
The result is a vendor lock-in.
Consequences
When a market (such as the one in the tale above) is dominated by vendor lock-ins, the producers benefited by the lock-in have little, if any, incentive to make better products. Their sales are guaranteed by the lock-in situation, not by their superior product in a fair market.
On the other hand, other producers will have an extremely hard time for competing, as their products will be almost unusable for the buyers.
The moral is that the lock-in situation is bad for either the potential users of the product locked-out (the B-type car above) and the locked-in one (the A-type car). Even if a consumer would never choose the locked-out product, the lack of competition will adversely affect the evolution of the product they do choose. The lock-in is bad for everyone: all consumers and all producers but the locker ones.
And this relates to Windows vs. Linux in what way?
In a really straightforward way. Microsoft, cunning as they are, have tried their best to get as many lock-ins on the software market as they can. Ironically, instead of abhorring this practice, most Windows users happily continue not only using, but even defending the product. I shudder at the simpleton comment that “freedom is not using Linux, but using Windows and Linux whenever you feel like it”. Literally taken, it is a very wise argument. But unfortunately the reality is not so simple: using Windows helps enforce a lock-in that keeps Linux out (while in this case the contrary is not true). You can not use Windows/Linux 50/50, because Windows asks you for monogamy.
The many lock-ins that MS has forced down the throats of the users, while the latter still claim them to be benefits of Windows include (as mentioned at the beginning):
One argument I tend to hear from Windows users is that in Windows you can do as much as you can with Linux, and that the technical advantages of Linux only show up if you are really an utter geek. This is one of (I hope) a series of entries in my blog, illustrating some cases where this doesn’t hold: I took advantage of tools provided by Linux in a way that anyone could have, not just geeks.
The moral of it all is that Windows encourages a lack of choice and flexibility that makes users tend not to be creative, and think the cage Windows keeps them in is actually a shelter from the storm, when it’s not. They think that what can’t be done with Windows, needs not be done. I think otherwise…
Today I will try to provide an example in which hard links can be useful. Under Windows XP hard links can be created, using the fsutil utility, but only for NTFS file systems, and only by the Administrator account (and only from the command line). If you want to learn more about links and specially Windows links, read this interesting sell-shocked.org article.
The problem
I download a lot of music from Jamendo, using the BitTorrent p2p protocol. After having downloaded a given album, I tend to leave the torrent open, so that people can continue uploading from my computer.
However, I also want to have my music collection tidy and ordered, so I immediately organize the newly-dowloaded songs moving them to a neat directory tree I have, will all my music.
So, there is a conflict between keeping the files in the bittorrent download/upload dir, and properly organizing them. I don’t want to have to wait until I decide to stop sharing a file to organize it, and I don’t want to risk deleting the files if I remove them from the bittorrent client before saving them elsewhere. I could get over all this by simply making a copy of the files… but then I would be filling twice as much disk space, and with GBs of shared files, this is not neat at all.
The solution
What I do is hardlink all the downloaded files to their final location. If I download all torrents to /scratch/ktorrent/, a downloaded album will look like that:
% ls /scratch/ktorrent/album1/
song1.ogg song2.ogg song3.ogg [...]
If I want to save the album under my artist1 directory, I do the following:
% mkdir /scratch/music/artist1/album1
% ln /scratch/ktorrent/album1/* /scratch/music/artist1/album1/
This way all the “song*.ogg” files will appear to be in both /scratch/music/artist1/album1/ and /scratch/ktorrent/album1/ at the same time.
Benefits:
1 – I can keep sharing the files in /scratch/ktorrent/album1/, while listening to and/or manipulating the /scratch/music/artist1/album1/ files as if I had 2 copies of each.
2 – The total size is not affected. The hard links do not “occupy” space (only a few bytes each).
3 – I can delete the files in the shared directory without any fear. Only the “copy” in /scratch/ktorrent/ disappears, while the other “copy” in /scratch/music/artist1/album1/ becomes the only copy (just as if it had always been a “normal” file, and the only one).
Recall that all files are hard links. Normally a given file is the only hard link to a given piece of data in the hard disk, but there can be more “links” pointing to that data. When we remove files, we only remove the “link” pointing to the data.
This is a short HowTo for making unicode work in Linux, specifically in the command line. Yet more specifically, in the konsole terminal. This is useful if you want to be able to use characters like ‘ñ’ or accents like in ‘á’ and ‘ö’.
1 – Modify your shell locale variables
You need locale settings that support UTF (for example en_US.UTF-8). For that, you can add the following lines to .tcshrc or whatever script run at login:
setenv mylang en_US.UTF-8
setenv LANG $mylang
setenv LC_CTYPE $mylang
setenv LANGUAGE $mylang
setenv LC_ALL $mylang
The ‘$mylang’ thing is just because I’m lazy, and I might want to change them all in the future, and I don’t want to type too much.
2 – Modify your global locales
I don’t know if this is needed, but it doesn’t hurt. In Debian:
% dpkg-reconfigure locales
and follow the instructions, using en_US.UTF-8 or something similar as default.
3 – Modify the encoding of Konsole
In the menus:
Settings->Encoding->Unicode (utf8)
Make this permanent with:
Settings->Save as Default
Then choose xterm and not linux as keyboard setting:
Settings->Keyboard->Xterm (XFree 4.x.x)
You can make this permanent in the Session tab of:
Settings->Configure Konsole
namely inserting “xterm” in the box labeled “$TERM”.
If you follow these instructions, you will be able to introduce non-ASCII text in the terminal, and use non-ASCII filenames without problem.
I have been using Subversion for a while (after having it recommended by my colleague Thomas), and I must confess I’m a happy user. Subversion is a revision control system, designed to supersede, and replace, the (maybe) more popular CVS.
Subversion (svn) is good for much more than collaborative development, as a single person can keep track of versions of her own documents/scripts/whatever. Usually you only want the last version of whatever you work with. But whenever you find yourself saving a version somewhere else, to keep it like that even if further changes are made to the “current” version, svn is your friend. Whenever you wish you had saved an earlier version of the stuff you’re working with, you’re missing (know it or not) svn.
I came across a blog post [es] talking about Windows 7, the planned sucessor of the current Windows Vista. The same can be found elsewhere, e.g. in Ars Technica.
The article summarized some features that Windows users would like to see in W7. You can also see a picture with the whole W7 wishlist. What struck me was that, although the Redmond giant tried its best to copy every single innovation from free software, they still missed important points that users value enough to make a wishlist out of them.
Some points in the list are new and exciting. Some others are everyday things for us free software users, and it’s so amazing that Windows still does not include them:
Maybe some slipped through, but I’m too tired to be more throughout.
Actually it is two applications I want to highlight: Filelight and Baobab. Both are disk usage analyzers, the former for KDE (see Figure 1), and the latter for GNOME (see Figure 2).
Figure 1: Filelight (click to enlarge)
Figure 2: Baobab (click to enlarge)
A disk usage analyzer is a tool to conveniently find out how much hard disk space different directories and files are taking up. It combines the effectiveness of the Unix du (if you never used it, stop here and do a man du in your command line immediately. If you do not know what that “command line” thingie is, whip yourself in the back repeatedly), with the convenience of a visual clue of how large directories are compared to one another.
From the two DUAs I mention, I largely prefer Filelight, for some reasons:
1 – When I want to open a terminal in a location chosen from the DUA window, with Baobab it’s two clicks away: “Open file manager here”, then “Open terminal here” in the file manager. With Filelight, it’s just one click: “open terminal here”. Plus Filelight has a handy locator bar at the top, showing the full path to the current location (useful to copy-and-paste with the mouse to an already open terminal).
2 – Filelight shows directories up to individual files. Baobab just dirs.
3 – With Filelight, navigation up and down (and back and forward) in the dir tree is a breeze (web browser-style). With Baobab, it’s a pain.
4 – The presentation is similar, but the one of Filelight is slightly nicer, with more info when the mouse is hovered over the graph.
Probably Baobab can be easily made to behave like Filelight. I just tried them both, and liked the latter better on first sight. I tried Baobab first, and I found some things lacking. When I tried Filelight, five minutes later, I just thought “These are the details Baobab was missing!”
Sin más razón que alimentar mi ego, aquà copio y pego un par de comentarios mÃos en una noticia de Menéame (8 razones de un usuario de Windows para no cambiar a Linux).
Me gustan sobremanera los comentarios #19 y #20. Analizadlos con un poco de rigor: los Windowseros “talibanes” (y los Linuxeros crÃticos) critican Linux porque falta software comercial (juegos y otros) y drivers. Los Linuxeros “talibanes” (y los Windowseros crÃticos) critican Windows porque se cuelga, porque no es seguro, etc.
Si os dáis cuenta, las ventajas de Windows sobre Linux son ajenas a Windows, mientras las ventajas de Linux son intrÃnsecas a este. Es decir: mañana las compañÃas de soft podrÃan decidir sacar todos sus productos solo para Linux, y la ventaja de Windows se vendrÃa abajo. Al revés, no hay manera en el mundo de que la ventaja de Linux se elimine, a menos que alguien reescriba Windows de cero y lo convierta en UNIX 2.0 o algo asÃ.
Yo alucino con los argumentos pro-Windows de la gente. Tomemos uno muy recurrente en este hilo: MSN. La gente dice que no pueden/quieren dejar de usar Windows porque (entre otros motivos), quieren usar el cliente MSN. El problema no es la calidad técnica de dicho cliente o de su protocolo, porque hay otros protocolos y clientes mejores (eso nadie lo duda). El problema es que MSN tiene un protocolo privativo, que MS puede cambiar como y cuando quiera, y al ser una aplicación popular, la gente se ve obligada o bien a usar clones que por fuerza andarán más “atrás” en compatibilidad y cualidades que el cliente nativo, o a usar el cliente nativo en el OS nativo.
Reflexionemos: estamos diciendo que hay un protocolo inferior que nos obliga a usar un cliente concreto, y este a su vez nos obliga a usar un SO concreto. ¿Y esto es una razón a favor de usarlo? Para mà es una razón en contra de usarlo. ¿Qué garantÃa de calidad se puede exigir a un productor en un mercado cautivo? ¿Cómo puedo ser tan necio de regalar mi libertad a cierto proveedor, y usar el único producto del mercado que me exige exclusividad, cuando hay otros productos mejores, y que no me la exigen? Si hay un(os) protocolo(s) de mensajerÃa que es(son) abierto(s), y tiene(n) mil clientes diferentes (por lo que puedo elegir cliente) de los cuales muchos son multiplataforma (y por tanto puedo elegir el SO), ¿no es esto, precisamente, una razón poderosa para usar ese protocolo, y no MSN?
Vivimos en un mundo de borregos.
« Previous Page — « Previous entries « Previous Page · Next Page » Next entries » — Next Page »