mirror of
https://github.com/RROrg/rr.git
synced 2025-06-21 05:51:05 +08:00
format
This commit is contained in:
parent
b1a76cc7f4
commit
ad528f0de2
@ -10,24 +10,25 @@ PIDFILE=/var/run/dhcpcd/pid
|
|||||||
[ -f $CONFIG ] || exit 0
|
[ -f $CONFIG ] || exit 0
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
start)
|
start)
|
||||||
echo "Starting dhcpcd..."
|
echo "Starting dhcpcd..."
|
||||||
start-stop-daemon -S -x "$DAEMON" -p "$PIDFILE" -- -f "$CONFIG"
|
start-stop-daemon -S -x "$DAEMON" -p "$PIDFILE" -- -f "$CONFIG"
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
echo "Stopping dhcpcd..."
|
echo "Stopping dhcpcd..."
|
||||||
start-stop-daemon -K -x "$DAEMON" -p "$PIDFILE" -o
|
start-stop-daemon -K -x "$DAEMON" -p "$PIDFILE" -o
|
||||||
;;
|
;;
|
||||||
reload|force-reload)
|
reload | force-reload)
|
||||||
echo "Reloading dhcpcd configuration..."
|
echo "Reloading dhcpcd configuration..."
|
||||||
"$DAEMON" -s reload
|
"$DAEMON" -s reload
|
||||||
;;
|
;;
|
||||||
restart)
|
restart)
|
||||||
"$0" stop
|
"$0" stop
|
||||||
sleep 1 # Prevent race condition: ensure dhcpcd stops before start.
|
sleep 1 # Prevent race condition: ensure dhcpcd stops before start.
|
||||||
"$0" start
|
"$0" start
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Usage: $0 {start|stop|restart|reload|force-reload}"
|
echo "Usage: $0 {start|stop|restart|reload|force-reload}"
|
||||||
exit 1
|
exit 1
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
@ -1,20 +1,20 @@
|
|||||||
[global]
|
[global]
|
||||||
workgroup = WORKGROUP
|
workgroup = WORKGROUP
|
||||||
server role = standalone server
|
server role = standalone server
|
||||||
obey pam restrictions = yes
|
obey pam restrictions = yes
|
||||||
map to guest = Bad User
|
map to guest = Bad User
|
||||||
usershare allow guests = yes
|
usershare allow guests = yes
|
||||||
dfree command = /usr/bin/df
|
dfree command = /usr/bin/df
|
||||||
|
|
||||||
[arpl]
|
[arpl]
|
||||||
browseable = yes
|
browseable = yes
|
||||||
public = yes
|
public = yes
|
||||||
path = /mnt
|
path = /mnt
|
||||||
guest ok = yes
|
guest ok = yes
|
||||||
printable = no
|
printable = no
|
||||||
read only = no
|
read only = no
|
||||||
writable = yes
|
writable = yes
|
||||||
create mask = 0600
|
create mask = 0600
|
||||||
directory mask = 0700
|
directory mask = 0700
|
||||||
force user = root
|
force user = root
|
||||||
force group = root
|
force group = root
|
||||||
|
@ -22,12 +22,11 @@ export DSMROOT_PATH="/mnt/dsmroot"
|
|||||||
export PATH="${PATH}:/opt/arpl"
|
export PATH="${PATH}:/opt/arpl"
|
||||||
|
|
||||||
if [ -f ${BOOTLOADER_PATH}/.locale ]; then
|
if [ -f ${BOOTLOADER_PATH}/.locale ]; then
|
||||||
export LANG="`cat ${BOOTLOADER_PATH}/.locale`"
|
export LANG="$(cat ${BOOTLOADER_PATH}/.locale)"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -d /opt/arpl/lang ]; then
|
if [ -d /opt/arpl/lang ]; then
|
||||||
for F in `ls /opt/arpl/lang/*.mo`
|
for F in $(ls /opt/arpl/lang/*.mo); do
|
||||||
do
|
|
||||||
install "${F}" "/usr/share/locale/$(basename $F .mo)/LC_MESSAGES/arpl.mo"
|
install "${F}" "/usr/share/locale/$(basename $F .mo)/LC_MESSAGES/arpl.mo"
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/usr/bin/env ash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
function use() {
|
function use() {
|
||||||
echo "Use: ${0} junior|config"
|
echo "Use: ${0} junior|config"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user