Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- #
- # created by OuNiS 07.2024
- #
- # pastebin: https://pastebin.com/RydAtzgD
- MODULE_NAME=".ounis-funcs"
- echo "$MODULE_NAME - załadowane..."
- listBluetoothDevs () {
- eche "\nlista urządzeń bluetooth:\n--------------------------"
- # bluetoothctl devices > bluet_devices.txt
- # for line in $(cat bluet_devices.txt); do
- # echo $line
- # done
- # see: https://pastebin.com/wy0ZLGRH
- # https://computingforgeeks.com/connect-to-bluetooth-device-from-linux-terminal/
- if [[ -n `which bluetoothctl` ]]; then
- (bluetoothctl devices) | while read line || [[ -n $line ]] ;
- do
- eche $CL_BLUE$CL_BOLD"$line"
- done #< <(bluetoothctl devices)
- result=$?
- eche $CL_DEF
- return $result
- else
- return 1
- fi
- }
- funcsList () {
- cat $MODULE_NAME | grep \(\) | cut -d " " -f1,2
- }
- alias funcs='funcsList'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement