Rollbacks changes
This commit is contained in:
parent
b38c35ab76
commit
962cdab9e8
1 changed files with 3 additions and 13 deletions
|
|
@ -1,20 +1,9 @@
|
|||
from netbox_agent.config import netbox_instance as nb
|
||||
from slugify import slugify
|
||||
from shutil import which
|
||||
import subprocess
|
||||
import socket
|
||||
import re
|
||||
import unicodedata
|
||||
|
||||
|
||||
def slugify(string):
|
||||
return re.sub(r'[-\s]+', '-',
|
||||
str(
|
||||
re.sub(r'[^\w\s-]', '',
|
||||
unicodedata.normalize('NFKD', string)
|
||||
.encode('ascii', 'ignore'))
|
||||
.strip()
|
||||
.lower()))
|
||||
|
||||
|
||||
def is_tool(name):
|
||||
'''Check whether `name` is on PATH and marked as executable.'''
|
||||
|
|
@ -64,7 +53,6 @@ def get_device_platform(device_platform):
|
|||
)
|
||||
return device_platform
|
||||
|
||||
|
||||
def get_vendor(name):
|
||||
vendors = {
|
||||
'PERC': 'Dell',
|
||||
|
|
@ -123,3 +111,5 @@ def get_mount_points():
|
|||
mp = mount_info[2]
|
||||
mount_points.setdefault(device, []).append(mp)
|
||||
return mount_points
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
editor.link_modal.header
Reference in a new issue