abra zsh config 2.0

This commit is contained in:
Andrey Anurin
2018-08-12 15:26:21 +03:00
parent 201abd09c4
commit 6b114440e2
1195 changed files with 68948 additions and 10539 deletions

View File

@@ -14,11 +14,15 @@ Each file should contain a line with the MAC address of the target device and
the network broadcast address. For instance, there might be a file
*~/.wakeonlan/leto* with the following contents:
00:11:22:33:44:55:66 192.168.0.255
```conf
00:11:22:33:44:55:66 192.168.0.255
```
To wake that device, use the following command:
wake leto
```sh
$ wake leto
```
For more information on the configuration file format, read the
[wakeonlan man page][2].

View File

@@ -6,6 +6,8 @@
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# function wake {
local config_file="$HOME/.wakeonlan/$1"
if [[ ! -s "$config_file" ]]; then
print "$0: invalid device file: $1" >&2
@@ -18,3 +20,5 @@ if (( ! $+commands[wakeonlan] )); then
fi
wakeonlan -f "$config_file"
# }