16 lines
379 B
Bash
16 lines
379 B
Bash
#!/bin/bash
|
|
|
|
# Prevent *.sh from returning itself if there are no matches
|
|
shopt -s nullglob
|
|
|
|
# Run every per-once script
|
|
run-parts --regex '.*\.sh$' /boot/per-once.d |
|
|
|
|
# Rename every per-once script
|
|
for f in /boot/per-once.d/*.sh; do
|
|
mv $f $(dirname $f)/$(basename $f .sh).$(date +%F@%H.%M.%S)
|
|
done
|
|
|
|
# Run every per-boot script
|
|
run-parts --regex '.*\.sh$' /boot/per-boot.d
|