Skip to main content

Happy New Year 2024

One min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Happy New Year 2024

I wish you all a very happy festive season, and may you continue to be curious about everything.

May this new year bring you new knowledge and skills, including Docker, Linux, Markdown and PHP.

May you take advantage of these technologies to create new projects and solve complex problems.

May you be surrounded by caring and inspiring people who will help you grow and succeed.

Above all, never stop being curious and learning.

All the best for you and your loved ones!

Customize your Linux prompt with Powerlevel10k

3 min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Customize your Linux prompt with Powerlevel10k

When you're working with Linux (also working with WSL thus), there are many ways to personalize your prompt. One of the simplest solutions is to use Powerlevel10k and its wizard.

In this article we're going to use a Docker container just to : test and discard. The Docker container will only be used to install Powerlevel10k, configure it and play with it. After that, it's up to you to see whether you like the interface and, if you do, to redo the installation on your machine rather than in Docker.

The tip comes from here

Using Adminer, pgadmin or phpmyadmin to access your Docker database container

3 min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Using Adminer, pgadmin or phpmyadmin to access your Docker database container

You've a dockerized application and one of its container is a MariaDB, MySQL or PostgreSQL service.

Your need is to start a web database management interface like Adminer, pgadmin or phpmyadmin and be able to access your tables and your records.

This can be done in just one command line instruction.

Docker inspect - Retrieve network's information

2 min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Docker inspect - Retrieve network's information

The docker inspect command is used to retrieve detailed information about various Docker objects, including images, containers, volumes, networks, and nodes. It provides a comprehensive overview of the object's configuration, state, and other relevant details.

The returned information is a JSON representation of the object.

One use case is to be able to retrieve the name of the network used by a given container.

Linux Makefile - When to use a makefile

5 min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Linux Makefile - When to use a makefile

Coding your own makefile has the enormous, terribly powerful advantage of being able to centralize the commands you use on your project in a single place, whatever the nature of the project (php, javascript, nodeJs, markdown, etc.).

The presence of a file called makefile sends a clear message to anyone who comes to work on the project: Hey, have a look here, you'll find all the commands you need. And it's really easy to list existing commands (see my article Linux Makefile - Adding a help screen).

So, you can define an up command (you choose the name of the command) which will launch all the actions required to start the project; you could have down for just the opposite, check to check that the project is valid (e.g. launch static checks of the quality of your code), and so on.

Starting the default associated Windows program on WSL

2 min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Starting the default associated Windows program on WSL

Very often, I'm in my Linux console and I'd like to open a pdf file that I've just generated or, more simply, to open an html file. But how can I do this?

Without knowing the tip that is the subject of this article, at the moment I launch Windows Explorer from my console, I get then the well-known file explorer interface and there I double-click on the file I want to open and leave it to Windows, which knows which program to launch to open this or that extension.

In fact, it's much simpler...

Linux Makefile - Adding a help screen

8 min read
Christophe
Markdown, WSL and Docker lover ~ PHP developer ~ Insatiable curious.

Linux Makefile - Adding a help screen

By using a makefile, you know it already, you can gather in one place a lot of actions like make bash, make build, make deploy, ... just like I do when working on this blog (see my makefile on https://github.com/cavo789/blog/blob/main/makefile).

What's really nice is being able to type make at the command line without any other options and then get a screen with lists of existing commands and a short one-line explanation.

That's what we'll be looking at in this article.