Search 32 character long directories only with find

Let say I have a directory with a lot of subdirectories: 04762b39018e3cf4b1a2c6a304919b75 06e0caf156de30dd962cf6b9300aba66 1f1d0cb1b810336299cda5426d0f12f5 2fe7a428eb303da6846800fa20ab7ed4 41e0136413703b0685d6799f8a22a8e6 asdf 1234 Databases Some of this directories are exact 32 characters long, (md5hash actually) and I would like to find them. Recursive search is not required in this case. I tried with this command: find /root/my/subdir -maxdepth 1 -type… Read More Search 32 character long directories only with find

Select files before today with GNU find

I’m trying to select files created before today with GNU find but it does not work as I expect : $ find log/ -maxdepth 1 ! -newermt today -name "BACKUP*OK" log/BACKUP_copro-20230504_OK log/BACKUP_distrib-20230503_OK log/BACKUP_distrib-20230504_OK $ find log/ -maxdepth 1 -daystart ! -newermt today -name "BACKUP*OK" log/BACKUP_copro-20230504_OK log/BACKUP_distrib-20230503_OK log/BACKUP_distrib-20230504_OK $ But I expect this file only :… Read More Select files before today with GNU find

How to build relevant auto generating tags recommendation model in python

How to Build a Relevant Auto Generating Tags Recommendation Model in Python One of the most important features of any blog or website is its ability to recommend relevant tags to users. This not only helps users find related content easily, but it also improves the overall user experience. In this blog post, we’ll show… Read More How to build relevant auto generating tags recommendation model in python

How to construct a find statement using multiple bash script arguments

To find a file containing more than one case-insensitive search term, I’m doing: find . -iname "*first*" -iname "*second*" I’d like to turn this into a utility script, so that I can just type ./myfind.sh first second However, since brace expansion happens before variable expansion, I can’t do: #!/bin/bash find . {-iname "*${*}*"} Note that… Read More How to construct a find statement using multiple bash script arguments

If I set the value to find as a variable, why doesn't it work?

When calling the findProd function with the number 1, everything works correctly. However, if I replace the number 1 with the idToFind variable, the console outputs undefined. Why is this happening? P.S. in my file, if I print idToFind, the result is 1. addToCartButtons.forEach(button => { button.addEventListener(‘click’, (event) => { const idToFind = event.target.dataset.id; let… Read More If I set the value to find as a variable, why doesn't it work?