반응형 <개인공부> - IT/[Python]39 복수개의 값 리스트에서 지우기 (None, multiple data remove in list) 네트워크 장비에 접속해 그 출력을 파싱할 때 자주 필요한 기능으로 추후 빨리 찾기 위해서 기록해 놓는다. I use this feature really frequently when parsing network devices console's output. Basically, this post is for myself. 1. None 값을 지우기 (Remove None values in list) -> filter 함수 이용 (Using filter function) a = ['''TenGigabitEthernet1/13 unassigned YES TFTP administratively down down TenGigabitEthernet1/14 unassigned YES TFTP administrative.. 2020. 9. 11. Cisco ISE ERS API (Device Update) 오늘 날짜를 기준으로 (2020/8/25) PyPi에서 검색해서 사용할 수 있는 ISE ERS 라이브러리에는 Network Device의 정보를 업데이트 할 수 있는 함수가 구현되어있지 않다. As of today's date (08/25/2020), the Cisco ISE ERS library, which can be gotten from PyPi, does not have a update function to update the network device information. >>> https://pypi.org/project/ISE/ ISE Python wrapper for Cisco ISE ERS API pypi.org 회사 업무를 하던 중, ISE의 Network Device 정보를 업데이트.. 2020. 8. 26. Basic usage exchangelib (MS Exchange) MS Exchange is a intergrated software for email, calendar, tasks, and etc. There are many features that we can use. But this time, I introduce a basic usage of exchagelib with Python. Especially sending an email with an attachment. from exchangelib import * credentials = Credentials(username='yourusername', password='yourpassword') account = Account(primary_smtp_address='youremailaddress', crede.. 2020. 8. 1. Openpyxl - Make a report template Let's create a report template as shown above. import datetime import openpyxl from openpyxl.styles import Border, Side, Font, Alignment, PatternFill def createExcelFile(): # Excel File Creation nowDate = 'Report Date: ' + str(datetime.datetime.now().strftime('%Y-%m-%d')) wb = openpyxl.Workbook() ws = wb.active ws.title = 'SNMP Community' # Pretty display for the File font = Font(bold=True) alig.. 2020. 7. 30. 이전 1 2 3 4 5 6 7 ··· 10 다음 반응형