Commit 87b44a94 authored by Anton Midyukov's avatar Anton Midyukov

90-firsttime: do not create /etc/firsttime.flag, if /etc/firsttime.d/ is empty

parent 0e324db2
#!/bin/sh #!/bin/sh
# Run scripts from /etc/firsttime.d at first start # Run scripts from /etc/firsttime.d at first start
[ -f "/etc/firsttime.flag" ] || touch "/etc/firsttime.flag" [ -d /etc/firsttime.d ] || exit 0
[ "$(ls /etc/firsttime.d 2>/dev/null |wc -l)" != 0 ] || exit 0
[ -f /etc/firsttime.flag ] || touch /etc/firsttime.flag
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment