basename Questions
14
Solved
I'm trying to get the name of the Python script that is currently running.
I have a script called foo.py and I'd like to do something like this in order to get the script name:
print(Scriptname)
3
This doesn't work:
find "$all_locks" -mindepth 1 -maxdepth 1 -type d | basename
apparently basename cannot read from stdin - in any case basename requires at least one argument.
1
© 2022 - 2024 — McMap. All rights reserved.