Profile cover photo
Profile photo
Sylvain Leroux
IT/Computer science teacher - Looking for a career change
IT/Computer science teacher - Looking for a career change

Sylvain's posts

Post has shared content
⏯ Watch the video directly on
📂 Download the files used in this video from

Changing the extension of 20 filenames from .JPE to .JPG. Annoying waste of time ? Not that much if you know the prename command !

#Shell #Bash #Linux #Rename

Post has shared content
Who will be able to solve that challenge ❓

I typed that at my Bash prompt :

yesik:001$ echo '1 2 3' >
yesik:002$ cut -d' ' -f1,3 | read X Z
yesik:003$ echo $((X+Z))

And the result displayed by my shell is 0 (zero).
C'mon Bash : 1+3 is 4, not 0.
My bash don't know how to count ! Is it broken ?

As in the previous challenge, the goal is to be creative. There are easy solutions. And probably many others more subtle (well, I hope so 😋 )

🌟 Bonus unicorn points if you are able to explain why my code didn't work.

The rules :
▸ Your solution can stand on one line or several.
▸ Your solution must read input data from the file.
▸ Running line 003 must display the correct result.
▹ You are not allowed to change line 001 nor 003.

Post has shared content
⏯ Watch the video directly on
📂 Download the files used in this video from

This is the third & last part of my mini-series for beginner shell users : "How to Move Hundreds of Files in no Time".

After having used basic glob patterns in part 1, switched to the "find" command in part 2 -- we're now back to glob patterns. But this time to explore the "globstar" extension, to match files even when spread across several sub-directory levels...

#Shell #Bash #Linux #GlobPattern

Post has shared content
Who will be able to solve that challenge ⁇

By mistake,
I typed the following command in my Linux Bash 4.30 terminal :

stty intr y

How could I revert my terminal to a sane configuration ?

▸ A valid solution can only use the command line.
▹ You are not allowed to close the terminal, logout, or any other action that will recreate or disconnect from the TTY.
▹ My terminal emulator don't have any GUI menu to "reset" the terminal.

#Linux #Shell #Challenge

Post has shared content
Giving users more access to the programming side of the game development

More students are learning about the world of open source through video games. Open source games like FreeCiv and Minetest invite young gamers to dig into the source code, while projects like SpigotMC empower them to write plugins to extend their favorite games.

Unfortunately, the open source tools used to build games do not share the same prominence. Rochester Institute of Technology student Matt Guerrette hopes to help change that with Hatchit, his open source gaming engine.

Guerrette and fellow student Arsen Tufankjian created Hatchit in February 2016. They felt the popular game engines they used in class and for personal projects were more design-oriented and lacked some technical details they were looking for. Together, they decided to build their own gaming engine with the goal of exposing developers to the technical side of the process. "We want to give you more access to the programming side of the game engine," Guerrette said.

Hatchit is written in C/C++ and licensed in a mix of GPL and LGPL. The project was originally designed to take advantage of the DirectX APIs for development. However, Guerrette and Tufankjian ran into an unexpected event while they were getting started. Nvidia released the Vulkan APIs in competition with the DirectX APIs. They attempted to support both APIs simultaneously, but later opted to focus on Vulkan.


Post has shared content
⏯ Watch the video directly on
📂 Download the files used in this video from

Last week, I used glob patterns to move hundreds of files in no time using the shell on Linux or Unix-like systems. But this is not the only solution.

This time, I introduce the "find" command which is more suitable when your files are scattered among several levels of sub-directories. But at the expense of a more complex syntax though.

Post has shared content
It works in French too :

"Vim, c'est vi en Mieux !"

Joyeux 25ème anniversaire Vim. We love you !

#vim #vim25 #linux

Post has attachment
After years of resistance, I finally resigned...

... I have now a Facebook account :

👥 Join me :

🎓 Follow my brand page :

Post has shared content
At some point all my videos are processed through ffmpeg. It is so powerful and incredibly useful. And most of all, it is a very active project !
A new major version of the powerful, free, cross-platform and open source FFmpeg multimedia framework was released on October 27, 2016, for all supported platforms, including GNU/Linux, Mac OS X, and Microsoft Windows.
Dubbed "Hypatia" and cut from Git master on the 26th of October 2016, the new FFmpeg 3.2 branch is now considered stable, well-tested, and ready for production. It includes up-to-date library versions like libavutil 55.34.100, libavcodec 57.64.100, libavformat 57.56.100, libavdevice 57.1.100, libavfilter 6.65.100, libavresample 3.1.0, libswscale 4.2.100, libswresample 2.3.100, and libpostproc 54.1.100.

For a complete list of the changes and improvements implemented in the major FFmpeg 3.2 "Hypatia" release, we recommend that you check out the Git changelog.
FFmpeg 3.2 arrives approximately four months after the release of FFmpeg 3.1 "Laplace," which reached end of life with the FFmpeg 3.1.5 maintenance update announced earlier this week right here on this space.
FFmpeg is a very popular project used in numerous open source and commercial software, including media players and games. It's an essential component of a GNU/Linux operating system, providing support for the latest audio and video codecs. Therefore, we strongly encourage all users to update to the FFmpeg 3.2 "Hypatia" release as soon as it lands in the stable repositories of their favorite distro. The FFmpeg 3.2 sources are available for download right now.

Post has shared content
Grouping files scattered among several sub-directories could be a boring and time-consuming task if you only rely on your mouse & the graphical user interface of your system.

But using the command line interface that could be done in only few seconds !

This is the first video of a three part mini-series. Here, I will focus on using basic glob patterns to let the shell generate long list of filenames for you.

#Shell   #Linux   #Unix   #GlobPatterns  
Wait while more posts are being loaded