File: portable_realpath

package info (click to toggle)
btllib 1.4.10%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 3,340 kB
  • sloc: cpp: 61,642; sh: 301; python: 222; makefile: 6
file content (6 lines) | stat: -rw-r--r-- 215 bytes parent folder | download
1
2
3
4
5
6
#!/bin/bash

# MacOS does not necessarily have coreutils installed, but Python should be as btllib requires it
function portable_realpath() {
  python3 -c 'import os, sys; print(os.path.realpath(sys.argv[1]))' $1
}