Skip to content

Commit 32a181b

Browse files
committed
treewide: fixup docstrings with newlines
Add the necessary newlines for sphinx-napoleaon to parse the docstrings correctly. Signed-off-by: Rouven Czerwinski <[email protected]>
1 parent 03fa105 commit 32a181b

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

labgridhelper/barebox.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@
33

44
def get_commands(command):
55
"""Returns the available commands of a running Barebox bootloader
6+
67
Args:
78
command (BareboxDriver): An instance of the BareboxDriver
9+
810
Returns:
911
list: list of the available commands
1012
"""
@@ -19,8 +21,10 @@ def get_commands(command):
1921

2022
def get_globals(command):
2123
"""Returns the global variables of a running Barebox bootloader
24+
2225
Args:
2326
command (BareboxDriver): An instance of the BareboxDriver
27+
2428
Returns:
2529
dict: name as key and value as key-value
2630
"""
@@ -30,9 +34,11 @@ def get_globals(command):
3034

3135
def devinfo(command, device):
3236
"""Returns the devinfo as dict
37+
3338
Args:
3439
command (BareboxDriver): An instance of the BareboxDriver
3540
device (string): device to call devinfo on
41+
3642
Returns:
3743
dict: parameters
3844
"""

labgridhelper/linux.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,11 @@ def get_systemd_status(command):
3737

3838
def get_commands(command, directories=None):
3939
"""Returns the commands of a running linux system
40+
4041
Args:
4142
command (CommandProtocol): An instance of a Driver implementing the CommandProtocol
4243
directories (list): An optional list of directories to include
44+
4345
Returns:
4446
list: list of commands available under linux
4547
"""
@@ -60,9 +62,11 @@ def get_commands(command, directories=None):
6062

6163
def get_systemd_service_active(command, service):
6264
"""Returns True if service is active, False in all other cases
65+
6366
Args:
6467
command (CommandProtocol): An instance of a Driver implementing the CommandProtocol
6568
service (str): name of the service
69+
6670
Returns:
6771
bool: True if service is active, False otherwise
6872
"""
@@ -75,9 +79,11 @@ def get_systemd_service_active(command, service):
7579
def get_interface_ip(command, interface="eth0"):
7680
import re
7781
"""Returns the global valid IPv4 address of the supplied interface
82+
7883
Args:
7984
command (CommandProtocol): An instance of a Driver implementing the CommandProtocol
8085
interface (string): name of the interface
86+
8187
Returns:
8288
str: IPv4 address of the interface, None otherwise
8389
"""
@@ -108,8 +114,10 @@ def get_interface_ip(command, interface="eth0"):
108114

109115
def get_hostname(command):
110116
"""Returns the hostname
117+
111118
Args:
112119
command (CommandProtocol): An instance of a Driver implementing the CommandProtocol
120+
113121
Returns:
114122
str: hostname of the target, None otherwise
115123
"""
@@ -121,10 +129,12 @@ def get_hostname(command):
121129

122130
def systemd_unit_properties(command, unit_properties, unit=''):
123131
"""Yields the values of the properties of a unit
132+
124133
Args:
125134
command (CommandProtocol): An instance of a Driver implementing the CommandProtocol
126135
unit_properties (iterable): Names of the properties of interest
127136
unit (str, optional): The systemd unit of interest, defaults to empty (systemd manager itself)
137+
128138
Yields:
129139
str: Property value of the unit
130140
"""

0 commit comments

Comments
 (0)