Skip to main content

a silhouette of a person's head and shoulders, used as a default avatar

Curso de Vim: La ayuda de #Vim

Aprendamos a utilizar y consultar la propia ayuda que ofrece el editor Vim

La documentación de un proyecto es una pieza fundamental. Tener una documentación actualizada, detallada y que cubra los aspectos de uso y explotación de una herramienta es un punto extra.

Dentro de esa documentación la ayuda que pueda ofrecer una herramienta es una buena forma de resolver dudas y dar a conocer todas las posibilidades que ofrece dicha herramienta.

El edito Vim, en ese aspecto es un buen ejemplo. La propia ayuda de Vim es útil y explora todas las posibles opciones que ofrece Vim. Veamos cómo explorar la ayuda de Vim y ver qué opciones ofrece.

Este artículo es una nueva entrega del curso “improVIMsado” que desde hace meses vengo publicando en mi blog sobre el editor Vim y que puedes seguir en estos enlaces:

La ayuda de Vim

Dentro del editor Vim, siempre podemos cosultar la propia ayuda que ofrece (en inglés) estando en modo normal con el comando:

:help

O con :h que es el modo abreviado. Y nos abrirá una ventana (normalmente en la parte superior) con la ayuda de Vim.

Ayuda de un término

Pero también podemos buscar información de forma más específica sobre un tema o consulta con:

:h <consulta>

Con esto, Vim nos mostrará la ayuda que existe para la <consulta> que hagamos.

Por ejemplo, si queremos buscar sobre el comando :quit, escribiremos lo siguiente:

:h quit

Al pulsar Enter, Vim nos abrirá una ventana en la parte inferior que muestra la ayuda que existe sobre ese comando. Pero ¿qué pasa si no sabemos exactamente el comando que buscamos y queremos escribir algo y que Vim nos muestre si hay temas sobre eso?

En Vim funciona muy bien el autocompletado. Podemos buscar ayuda sobre lo que tenga Vim con la palabra “run”. Para ello tenemos dos opciones:

  • Podemos escribir :h run y pulsar sobre Ctrl+D y Vim nos mostrará una lista de comandos que contienen dicha palabra
  • Podemos escribir :h run y pulsar la tecla Tabulador y Vim nos irá pasando por los comandos que hemos visto que aparecían anteriormente hasta que encontremos el que nos interesa.

Buscando en la ayuda

Si abrimos la ayuda en general con :help (o con :h en modo abreviado) también podemos buscar dentro de la ayuda de la manera usual en que buscamos en Vim con /. Por ejemplo:

/ quit

Podremos ir navegando por todas las coincidencias que Vim nos encuentre de la palabra buscada, de la manera normal que lo hacemos en Vim.

Dentro de la ayuda de Vim, a veces aparecen enlaces a otras partes o secciones de la ayuda. Para navegar por esos enlaces deberemos utilizar Ctrl ]

Y una vez consultado ese enlace, si queremos regresar al punto desde el que saltamos podemos hacer con Ctrl o

Helpgrep

También podemos utilizar el comando :helpgrep <consulta>. Por ejemplo:

:helpgrep quit

Que nos busca un término dentro de toda la ayuda de Vim y nos muestra donde se utiliza. Para ver en una pantalla inferior todas las partes donde aparece el término buscado pulsaremos

:copen

Podremos ir navegando por todas las opciones mostradas y cuando queramos consultar una pulsaremos sobre ella Enter.

También podemos ir recorriendo todas las opciones hacia adelante o atrás respectivamente con estos comandos:

:copen

:cprev

Estos son solo unos fundamentos esenciales a la hora de buscar en la ayuda de Vim. Si quieres más información, ahora ya sabes…

:help help

the avatar of openSUSE Heroes

Playing with Etherpad-lite

When updating to the latest etherpad-lite version 1.8.7 (including quite some bug fixes), we also revisuted the currently installed plugins and updated them to their latest version as well, as usual.

To get some impressions about the usage of our Etherpad instance, we also enabled the ether-o-meter plugin now, which is now producing some nice live graphs and statistics here: https://etherpad.opensuse.org/metrics

We also enabled some additional styles now and hope this makes the usage of Etherpad even more fun and productive for you. If you want to have some more modules enabled (or just want to say "hello"), feel free to contact us! Either via an Email to or by reaching out for us at irc.opensuse.org channel #opensuse-admin.

the avatar of openQA-Bites

What are Needles

In this blog post we are going to give you the easiest introduction to what needles are and how you can use them. While there are many good talks and documentation on needles out there, it took me longer than it should have to find a easy-to-use and easy-to-understand introduction into this topic alone. This blog post should fill this gap.

the avatar of Efstathios Iosifidis

4 τρόποι για να ενώσετε πολλά .pdf σε ένα μεγάλο

4 τρόποι για να ενώσετε πολλά .pdf σε ένα μεγάλο

ΤΟ ΠΡΟΒΛΗΜΑ

Έστω ότι συγκεντρώνετε πολλά αρχεία pdf. Είτε σχολή λέγεται αυτό, είτε εργασία; Το πρόβλημα που αντιμετωπίζουν πολλοί είναι η εύρεση της πληροφορίας όταν την χρειάζονται. Σίγουρα μπορεί να γίνει και μέσα από το λειτουργικό σύστημα αλλά αρκετές φορές δεν έχει επιτυχία. Οπότε μια καλή λύση είναι η ένωση σε ένα αρχείο, όλων των pdf που έχουν το ίδιο αντικείμενο, ώστε να αναζητάτε μέσα από το πρόγραμμα ανάγνωσης pdf. Εδώ θα εξετάσουμε πως μπορείτε με μια κίνηση, να ενώσετε πολλά pdf.

Η ΛΥΣΗ

Μέχρι στιγμής, βρήκα 4 λύσεις:

ΛΥΣΗ 1:

Εγκαταστήστε το poppler-utils με την παρακάτω εντολή:
#Σε openSUSE
sudo zypper in poppler-tools

#Σε Ubuntu/Linux Mint
sudo apt install poppler-utils

#Σε Arch Linux
sudo pacman -S poppler

Στη συνέχεια, στον κατάλογο με τα pdf, εκτελέστε την εντολή:
pdfunite *.pdf out.pdf


ΛΥΣΗ 2:

Εγκαταστήστε το πρόγραμμα pdftk με την παρακάτω εντολή:
#Σε openSUSE
sudo zypper in pdftk

#Σε Ubuntu/Linux Mint
sudo apt install pdftk

#Σε Arch Linux
sudo pacman -S pdftk

Έστω ότι είστε φοιτητής και έχετε οργανώσει τις διαλέξεις ανά φάκελο (με ότι πιθανά αρχεία να σας έχουν δώσει). Δώστε την παρακάτω εντολή:
pdftk lecture?/*.pdf cat output lecturesall.pdf

Αυτό που θα κάνει είναι να μπει σε ένα ένα φάκελο, θα δει αν έχει κάποιο αρχείο pdf και θα το ενώσει σε ένα pdf.

ΛΥΣΗ 3:

Χρήση latex. Εγκαταστήστε το παρακάτω πακέτο.
#Σε openSUSE
sudo zypper in texlive-latex-base

#Σε Ubuntu/Linux Mint
sudo apt install texlive-latex-base

#Σε Arch Linux
sudo pacman -S texlive-latexextra

Εστω ότι έχετε τα αρχεία file1.pdf και file2.pdf στον ίδιο φάκελο. Φτιάξτε το αρχείο output.tex με το περιεχόμενο:
\documentclass{article}
\usepackage{pdfpages}
\begin{document}
\includepdf[pages=-]{file1}
\includepdf[pages=-]{file2}
\end{document}

Εκτελέστε την εντολή:
pdflatex output.tex


ΛΥΣΗ 4:

Μπορείτε να κατασκευάσετε ένα script στο Nautilus:
Εγκαταστήστε το πακέτο (εάν δεν το έχετε):
#Σε openSUSE
sudo zypper in poppler-tools

#Σε Ubuntu/Linux Mint
sudo apt install poppler-utils

#Σε Arch Linux
sudo pacman -S poppler

Κατασκευάστε ένα αρχείο μέσα στον κατάλογο nautilus/scripts
nano ~/.local/share/nautilus/scripts/merge_pdfs.sh

Στην συνέχεια προσθέστε το παρακάτω κώδικα:
#!/bin/sh
CLEANED_FILE_PATHS=$(echo $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS | sed 's,.pdf /home/,.pdf\\n/home/,g')
echo $CLEANED_FILE_PATHS | bash -c 'IFS=$'"'"'\n'"'"' read -d "" -ra x;pdfunite "${x[@]}" merged.pdf'

Το αρχείο αυτό κάντε το εκτελέσιμο (πατήστε δεξί πλήκτρο πάντω του > Ιδιότητες > Δικαιώματα > Να επιτρέπεται η εκτέλεση του αρχείου ως προγράμματος). Εναλλακτικά δώστε την παρακάτω εντολή:
chmod +x ~/.local/share/nautilus/scripts/merge_pdfs.sh

Τώρα για να ενώσετε τα αρχεία, φωτίστε τα στον φάκελο στο Nautilus, πατήστε δεξί πλήκτρο > Δέσμες ενεργειών (scripts) και επιλέξτε το merge_pdfs.sh για να σας εξάγει ένα αρχείο pdf.

Εάν βρήκατε κάποιον τρόπο εύκολο στην χρήση, ενημερώστε και τους φίλους σας ώστε να μην παιδεύονται.
the avatar of YaST Team

Digest of YaST Development Sprint 117

It’s time for more development news from the YaST Team. In this occasion, most of the work has gone into improving features already implemented in previous sprints and, thus, presented in former blog posts. That includes:

  • Improvements when writing wireless security settings for NetworkManager
  • Fixes in the new management of hibernation
  • Possibility to tweak the I/O device autoconfiguration in the installed system
  • Usability improvements regarding nested items in the table widget
  • Better LibYUI packaging including a revamped CMake build system
  • Enhancements in the YaST Autoinstallation module regarding partitioning
  • Many other improvements and fixes here and there

As you surely remember, in the previous sprint we added support for writing basic NetworkManager configuration during installation. But it was quite limited regarding wireless, so it only was capable to translate WPA-PSAK and open wireless configuration. During this sprint, we enhanced the NetworkManager config writers to support the same wireless setups that are currently supported by wicked (WEP, WPA-EAP…). In addition, some UI problems were found and fixed.

In the previous sprint we also improved the hibernation support by tuning the scenarios in which YaST adds the resume= parameter to the bootloader configuration. While testing that improved behavior, some problems were detected both by ourselves and by the awesome QA team at SUSE. Now all those inconvenients are fixed: the bootloader proposal is properly recalculated when needed, the resume parameter is not longer added for small swap devices and we improved the detection of virtual setups in which traditional hibernation is not wanted.

But not all the features we polished during this sprint are so recent. For several months, we have been describing the different steps in the implementation of support in YaST for I/O devices auto-configuration on s390 mainframes. The latest reference was on our blog post of sprint 105 (time flies!). But we still had one more thing in our TO-DO list and, since we recently had to modify the YaST2 Tune module to remove some obsolete settings, we decided to take the opportunity and also add the I/O device autoconfig checkbox to that module. See details and screenshots at this pull request.

We also improved the usability of our most recent LibYUI feature. In the YaST partitioner, which is so far the only application using the new feature to have nested rows in a table, the [Space] key did not only open or close tree branches in the ncurses text-mode interface. It also sent an “Activated” event (the counterpart of double-clicking an item in the Qt graphical user interface), resulting in a quite confusing behavior. See the fix for more detailed information.

And talking about LibYUI, we also decided it was time to tackle one big problem that we have been dragging for too long. The structure of our development repositories and our over-complicated CMake build environment was making too hard to add new features to LibYUI without risking breakage in the distributions. Every change implied a lot of extra synchronization work, which also was an obstacle for external contributions and maintaners of additional plugins and backends. After several weeks of work, we have now walked the first step out of that mess with the new CMake build system for LibYUI

And there is no YaST Team sprint without some news about AutoYaST. This time we have improved the part of the YaST Autoinstallation module that can be used to create and tweak the <partitioning> section of the AutoYaST profile. Apart from several small fixes (like improved visualization or fixes in the fstopt field), it’s now possible to manage <drive> sections to describe NFS and tmpfs file systems.

As usual, there would be much more to report like usability improvements and speedups in YaST Network, fixes in hwinfo or important updates in the documentation… but we need to go back to coding at some point!

So see you again in a couple of weeks with more news about YaST and, if everything works as expected, some reflections about the long-term future. Stay safe and have a lot of fun!

a silhouette of a person's head and shoulders, used as a default avatar

Juega al ajedrez en el servidor lichess en tu dispositivo móvil

Puedes descargar la aplicación libre oficial para jugar al ajedrez en el servidor lichess.org

imagen: Chema Madoz

Empezaba el año 2021 publicando en el blog un artículo sobre el servidor lichess.org para jugar al ajedrez. Puedes leer el artículo en este enlace:

Lichess.org es un servidor libre, y gratuito en el que registrarte y poder jugar al ajedrez y estudiar, aprender y retar a otras personas a jugar al ajedrez en multitud de variantes.

Pero no siempre estamos delante de nuestro equipo ¿entonces tenemos que dejar en modo pausa nuestros retos ajedrecísticos? ¡No! Conéctate a lichess.org desde tu dispositivo móvil.

Para conectarte a lichess.org puedes utilizar la aplicación oficial. Una aplicación para Android y Apple publicada bajo una licencia libre GPL v3, desarrollada en GitHub.

La única pega que podemos ponerle, es que no está disponible desde repositorios de aplicaciones libres como f-droid.

Así que únicamente la podremos instalar desde la tienda de Google y App Store. Aunque también podemos descargar la apk e instalarla en nuestro dispositivo.

Es una aplicación libre, gratuita y con todas las funcionalidades que nos ofrece lichess.org disponibles en nuestra palma de la mano.

Una buena opción a la hora de hacer tiempo en salas de espera y practicar nuestros mejores movimientos al ajedrez.

Dale jaque al rey, ¡tu mueves!

Enlaces de interés

a silhouette of a person's head and shoulders, used as a default avatar

Chinese Lunar Calendar – Plasmoides de KDE (169)

Hoy me complace presentar Chinese Lunar Calendar el plasmoide de KDE número 169 de la gran serie de los mismos mostrados en el blog y que nos ofrece la posibilidad de tener el calendario lunar chino en nuestro escritorio.

Chinese Lunar Calendar – Plasmoides de KDE (169)

Tenemos muchos plasmoides estilo reloj para Plasma, pero pocos para calendarios. Haciendo un rápida búsqueda por el blog me aparecen Calendar WL, Event Calendar (del cual hay que reconocer que es una bestia parda difícil de igualar), el reciente Weekday Grid y Persian Calendar, un plasmoide muy parecido al que os presento hoy.

Y es que si quieres tener el Calendario Linux Chino en tu escritorio éste es tu plasmoide, una alternativa al calendario tradicional de Plasma (DigitalClock applet).

Su instalación no es sencilla, así que os remito a su páginas de la KDE Store para obtener las instrucciones precisas.

Chinese Lunar Calendar - Plasmoides de KDE (169)

Y como siempre digo, si os gusta el plasmoide podéis “pagarlo” de muchas formas en la nueva página de KDE Store, que estoy seguro que el desarrollador lo agradecerá: puntúale positivamente, hazle un comentario en la página o realiza una donación. Ayudar al desarrollo del Software Libre también se hace simplemente dando las gracias, ayuda mucho más de lo que os podéis imaginar, recordad la campaña I love Free Software Day 2017 de la Free Software Foundation donde se nos recordaba esta forma tan sencilla de colaborar con el gran proyecto del Software Libre y que en el blog dedicamos un artículo.

Más información: KDE Store

¿Qué son los plasmoides?

Para los no iniciados en el blog, quizás la palabra plasmoide le suene un poco rara pero no es mas que el nombre que reciben los widgets para el escritorio Plasma de KDE.

En otras palabras, los plasmoides no son más que pequeñas aplicaciones que puestas sobre el escritorio o sobre una de las barras de tareas del mismo aumentan las funcionalidades del mismo o simplemente lo decoran.

the avatar of Nathan Wolf
the avatar of Santiago Zarate

Perl binaries are mismatched - the revenge of the lazy person

The uninvited eldrich terror

You use local::lib, and the pain unfolds: A shell is started, and you find a dreaded:

Cwd.c: loadable library and perl binaries are mismatched (got handshake key 0xdb00080, needed 0xdb80080)

Pennywise, because I could not find the right gif, from the Uninvited, of Sabrina's netflix

Which means: that the module (Cwd in this case) is not compatible (Because it’s an XS module) with your current version of perl, installed on your system: Likely it was compiled for a previous version, leadin to those binaries mismatching

Don’t panic!

I wrote about this however, I left out how to get to the point where you have already an usable Perl again?

The light

Instead of downloading local::lib from git as I used to do… this time I decided to do it on a much simpler way: use perl-local-lib from my distribution, and let it do the magic, I mean that’s why I run openSUSE Tumbleweed

 zypper in perl-local-lib
 rm -rf perl5-old || echo "First time eh?"
 mv perl5 perl5-old
 perl -MCPAN -Mlocal::lib -e 'CPAN::install(App::cpanminus)'
 cpanm App::MigrateModules
 perl-migrate-modules --from ~/perl5-old/lib/perl5 /usr/bin/perl

Et voilà, ma chérie!

It's alive!

the avatar of openSUSE News

Reducing the scope of software.opensuse.org

We have some exciting news to share regarding the consolidation of our web pages.

We’ve decided to drop functionality behind https://software.opensuse.org/distributions and instead provide a redirect to https://get.opensuse.org. Submit request can be found here https://github.com/openSUSE/software-o-o/pull/943.

Both sites were offering similar functionality for downloading install media. Both sites had to be updated with every Alpha, Beta, or changes to media descriptions. The new reduced scope of software-o-o will be purely browsing of available software. The scope of get-o-o won’t change. It will be media downloads and pointers to relevant documentation such as installation or upgrade instructions. We believe that these changes will help to keep it small and simple.

We’re happy to reduce duplication of efforts while not introducing further fragmentation as get.opensuse.org has been around for quite some time already.

Efforts to make the changes were discussed as part of the Web Development Sprint last week. There are descriptions for each distribution on get.opensuse.org to better let new users understand the difference in each openSUSE Distribution. Changes to software-o-o are also expected to be revamped in the future.

The next Web Development Sprint will take place on March 4 at 18:30 UTC on https://meet.opensuse.org/websprints. Notes from the sprint can be accessed at https://etherpad.opensuse.org/p/websprints.