Skip to content

Commit

Permalink
[sfputil]: Refactor and add support for presence, low-power mode and …
Browse files Browse the repository at this point in the history
…reset (sonic-net#90)

- Convert sfputil to 'Click'-based command line utility
- Refactor sfputilbase.py: Clean up API and convert to proper abstract base class to make implementation more straightforward
- Add support for querying SFP transceiver presence
- Add support for querying & setting low-power mode
- Add support for resetting SFP transceivers
  • Loading branch information
jleveque authored Aug 10, 2017
1 parent c7f6ff6 commit ac7ea4f
Show file tree
Hide file tree
Showing 7 changed files with 1,203 additions and 1,526 deletions.
8 changes: 8 additions & 0 deletions data/etc/bash_completion.d/sfputil
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
_sfputil_completion() {
COMPREPLY=( $( env COMP_WORDS="${COMP_WORDS[*]}" \
COMP_CWORD=$COMP_CWORD \
_SFPUTIL_COMPLETE=complete $1 ) )
return 0
}

complete -F _sfputil_completion -o default sfputil;
Loading

0 comments on commit ac7ea4f

Please sign in to comment.