13 lines
386 B
Markdown
13 lines
386 B
Markdown
---
|
|
title: "Seconds since last pacman sync"
|
|
date: 2022-05-19T08:45:13Z
|
|
tags: ["archlinux", "linux", "pacman"]
|
|
draft: false
|
|
---
|
|
|
|
We can echo the result of the current timestamp subtracted from the last edit timestamp in `/var/lib/pacman/local/*/desc`.
|
|
|
|
```
|
|
echo $(expr $(date +%s) - $(grep -rn -A 1 %INSTALLDATE% /var/lib/pacman/local/*/desc | grep -oP '\d{10,}$' | sort | tail -1))
|
|
```
|