Skip to content

Instantly share code, notes, and snippets.

@ertankayalar
Created November 23, 2024 03:13
Show Gist options
  • Save ertankayalar/c03a7f2677ba9dbaba8d3e97cb432a7e to your computer and use it in GitHub Desktop.
Save ertankayalar/c03a7f2677ba9dbaba8d3e97cb432a7e to your computer and use it in GitHub Desktop.
g810 install & setup ubuntu colors
#!/bin/bash
sudo apt -y install g810-led
FILE_PATH="/etc/g810-led/profile"
# Ensure the directory exists
sudo mkdir -p "$(dirname "$FILE_PATH")"
# Use cat to create the file with content
sudo cat <<EOF >"$FILE_PATH"
# Ubuntu
g logo 000096 # Blue
g indicators ffffff # White
g multimedia 009600 # Green
g fkeys ff7700 # Orange
g modifiers ff7700 # Orange
g arrows ffffff # Red
g numeric 00ff00 # Green
g functions ffffff # White
g keys ff00ff # Purple
g gkeys ffffff # White
k tilde ff0000 # Red
k 1 ff00ff # Red {
k 2 ff00ff
k 3 ff00ff
k 4 ff00ff
k 5 ff00ff
k 6 ff00ff
k 7 ff00ff
k 8 ff00ff
k 9 ff00ff
k 0 ff00ff # }
c # Commit changes
EOF
echo "g810 setup file is created at $FILE_PATH."
g810-led -p /etc/g810-led/profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment