Skip to main content

Bon, et maintenant, c'est possible de tooter depuis l'#IndieWeb?

‪Playing playmobil with my sons when my 4yo asks "say my name". Apparently "Heisenberg" wasn’t the expected answer.

Hey @LEGO_Group! My 4yo son received his first Lego set for his birthday and he *loves* it. Sadly, one piece is slightly bent & I can't build the third trolley :( Is there a way to order a replacement piece?

Dites, chez @bpost_fr, il y a quelqu'un qui veut bien dire à mon facteur de faire son boulot? Mon épouse est mère au foyer, présente à la maison 99% du temps quand le facteur passe, et pourtant on s'évertue à nous laisser des avis de passage dans la boîte aux lettres. J'aime pas être l'emmerdeur de service, mais là il y a matière à foutage de gueule.

Remove git branches older than X months

1 min read

For the example, we're deleting merged branches older than 3 months :

for k in $(git branch --sort=committerdate --remote --merged | grep -o -P "(?<=origin\/)[^ ]+"); do
  if [[ ! $(git log -1 --since='3 month ago' -s origin/$k) ]]; then
    git push --delete origin $k

Bon, @bpost_fr, les colis qui débordent de la boîte quand on est pas là, c'est une chose; mais l'avis de passage alors qu'on attend un colis urgent et qu'*on est présent* mais que le facteur à la flemme de sonner, ça commence à faire beaucoup.

Uniquement la moitié du temps, l'autre moitié, c'est pour remplir sa déclaration fiscale ^o)

Hello Mastodon

Triggering a command line on file change

1 min read

Today I was migrating a somewhat old codebase to Ruby on Rails 6.0.0. As per usual, this can be a very tidious job requiring a bunch of depencies to be updated as well. In this case, the Gemfile contains around 150 lines.

When I have to do that kind of job, the first thing I do is commenting out every single gem except for rails itself, then bundle update, then I re-add the other gems to the Gemfile.

It rarely goes smoothly, since every gem has it's own dependencies and sometime the bundle command has trouble to find a way to update everything in one go, so I usually re-add 2-5 gems at once then run bundle update on my modified Gemfile, until all the dependencies have been re-added.

The whole process of going back and forth to editing, saving, running the bundle command is somewhat exhausting, so today I decided to have a look at a more productive way to do this : the following command uses inotifywait to detect whenever I save the Gemfile then run bundle update automagically.

while inotifywait -e close_write Gemfile; do bundle update; done