- Install ExifTool (if not already installed):bash
sudo apt update sudo apt install exiftool - Run the command to view the metadata:bash
exiftool your_document.docx - To look for specific fields (like Author or Dates) quickly, you can use
grep:bashexiftool your_document.docx | grep -i "Author" exiftool your_document.docx | grep -i "Date"
Sherman IT
01 March 2026
on ubuntu, how can I check the author, date/time created, information of a .docx file?
26 February 2026
How can i use a special character as the HTML list item marker?
HTML
<ul class="special-bullets">
<li>Item one</li>
<li>Item two</li>
<li>Item three</li>
</ul>
CSS
.special-bullets {
list-style-type: none; /* remove default bullet */
padding-left: 1.4em; /* adjust indent as needed */
}
.special-bullets li::marker {
content: "★ "; /* ← your special character + space */
/* content: "✔ "; */
/* content: "➜ "; */
/* content: "🚀 "; */ /* emoji also works */
color: #e91e63; /* optional: color the marker */
font-size: 1.1em; /* optional: size */
}
You can also style the number in the same way:
ol.fancy-numbers li::marker {
content: counter(list-item) ". "; /* default is "1. " */
color: navy;
font-weight: bold;
}
23 February 2026
How to shrink file size of a pdf file?
sudo apt update
sudo apt install ghostscript
gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf
input.pdf: Replace with your original file name.output.pdf: The name of the new compressed file.
/screen setting makes the text look too blurry, try /ebook (150 dpi), which balances good quality with a smaller file size: gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/ebook -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf
-dPDFSETTINGS=/screen: 72 dpi, lowest quality, smallest size (best for >2MB requirement).-dPDFSETTINGS=/ebook: 150 dpi, medium quality, better for reading.-dPDFSETTINGS=/printer: 300 dpi, high quality, likely to keep the file over 2MB.
Knowing port number, how to kill a process which is using that port?
Find what's sitting on the port:
$ sudo lsof -i :8000(Replace 8000 with your port)Kill that specific listener:
$ sudo kill -9 <PID_FROM_LSOF>
If I am running -
$ gunicorn --bind 0.0.0.0:8000 app:app
[2026-02-23 10:38:25 -0500] [250191] [INFO] Starting gunicorn 25.1.0
[2026-02-23 10:38:25 -0500] [250191] [INFO] Listening at: http://0.0.0.0:8000 (250191)
[2026-02-23 10:38:25 -0500] [250191] [INFO] Using worker: sync
[2026-02-23 10:38:25 -0500] [250191] [INFO] Control socket listening at /home/shermanchen/dev/convShop2/gunicorn.ctl
[2026-02-23 10:38:25 -0500] [250193] [INFO] Booting worker with pid: 250193
When I run lsof, I get -
$ sudo lsof -i :8000
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
gunicorn 250191 shermanchen 3u IPv4 1077472 0t0 TCP *:8000 (LISTEN)
gunicorn 250193 shermanchen 3u IPv4 1077472 0t0 TCP *:8000 (LISTEN)
If I kill the 'booting worker' pid 250193, the gunicorn will not be killed. I have to kill the 'listening' pid 250191, to kill the gunicorn process.
$ sudo kill -9 250191
If I use ps, I got
$ ps aux | grep gunicorn
sherman+ 250690 0.0 0.0 9824 2172 pts/1 S+ 10:45 0:00 grep --color=auto gunicorn
Killing pid 250690 will not kill the gunicorn process.
18 February 2026
How to sort by time the result of the $ find command?
$ find . -iname "applied*" -type f -printf '%T+ %p\n' | sort -r
$ find . -iname "applied*" -type f -printf '%TY-%Tm-%Td %TH:%TM %p\n' | sort -r