mirror of
https://github.com/LukeSmithxyz/voidrice.git
synced 2026-03-20 01:37:45 +01:00
fixed issue with windows format : removal by sed
This commit is contained in:
parent
25b3aa275e
commit
f3654ec06a
@ -11,17 +11,17 @@ mac=$1
|
||||
|
||||
unix() {
|
||||
# Unix Format
|
||||
var=$( echo $mac | sed 's![-.]!!g;s!\(..\)!\1:!g;s!:$!!') ;
|
||||
var=$( echo $mac | sed 's![-.:]!!g;s!\(..\)!\1:!g;s!:$!!') ;
|
||||
}
|
||||
|
||||
cisco() {
|
||||
# Cisco Format
|
||||
var=$( echo $mac | sed 's![-.]!!g;s!\(....\)!\1.!g;s!.$!!') ;
|
||||
var=$( echo $mac | sed 's![-.:]!!g;s!\(....\)!\1.!g;s!.$!!') ;
|
||||
}
|
||||
|
||||
windows() {
|
||||
# Windows Format
|
||||
var=$( echo $mac | sed 's![-.]!!g;s!\(..\)!\1-!g;s!-$!!') ;
|
||||
var=$( echo $mac | sed 's![-.:]!!g;s!\(..\)!\1-!g;s!-$!!') ;
|
||||
}
|
||||
|
||||
choice=$(printf "Unix\\nCisco\\nWindows" | dmenu -i -p "Select required MAC format:")
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user