Skip to content

Instantly share code, notes, and snippets.

@valechelaru
valechelaru / searchDict.sh
Last active May 7, 2022 23:40
Small script that searches for highlighted text using the gnome-dictionary.
#!/bin/bash
# Put highlighted text into the clipboard buffer
xclip -out -selection primary
# Start the gnome-dictionary and search for the clipboard buffer
gnome-dictionary --look-up="$(xclip -o selection clipboard)"
@valechelaru
valechelaru / airpods_disconnect.sh
Created February 17, 2022 01:19
Simple aitpods disconnect bash script
#!/bin/bash
echo "Disconnect Airpods..."
bluetoothctl disconnect 00:00:00:00:00:00
@valechelaru
valechelaru / airpods-indicator.py
Last active May 16, 2022 19:18
Airpods GTK3 AppIndicator
#!/usr/bin/python3
import signal
import gi
import os
gi.require_version('Gtk', '3.0')
from gi.repository import Gtk as gtk
gi.require_version('AppIndicator3', '0.1')
from gi.repository import AppIndicator3 as appindicator
gi.require_version('Notify', '0.7')
@valechelaru
valechelaru / connectJBL_TUNE600BTNC.sh
Created February 16, 2022 21:43
Simple bash script to connect to my JBL bluetooth headphones
#!/bin/bash
echo "Connect to JBL Headphones..."
while true
do
bluetoothctl connect 00:00:00:00:00:00
if [[ $? -eq 0 ]]
then