Skip to content
This repository has been archived by the owner on Feb 19, 2023. It is now read-only.
/ g13-apps Public archive

Simple little applications for your G13 keyboard (for Linux)

License

Notifications You must be signed in to change notification settings

fusetim/g13-apps

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

G13 Apps

Simple little applications for your G13 keyboard. Very useful for g13 users.
Work In Progress — Applications are slowly developed step by step.

How does it work?

The G13 mini-applications will use the keys already used for this purpose in Windows :

  • Thus the L1-4 keys will be used to interact with the launched application.

  • The BD button will be used to return to the menu.

ℹ️

However we will not change the configuration of the G13 driver automatically. The configuration will have to be changed manually with the one supplied.

See the keybind g13-apps.bind.

Applications will be similar to the original G13. You will find a list of applications implemented or to be implemented.

What applications?

  • ✓ Menu — the application selector

  • ✓ Clock — analog and digital

  • ✓ Music Player — based upon MPRIS data

ℹ️

All applications can be disabled at compile time.
Now works with enum_dispatch v0.3.2!

ℹ️
Feel free to open an issue (or PR) to request another application.

Getting started

Prerequisites

First of all, you will need a recent Rust setup. See Rustup installation guide, if needed.

Before compiling g13-apps, you will need to know the paths to the in and out pipes of the G13 driver. By default, it’s /tmp/g13-0 (in) and /tmp/g13-0_out (out).

Set-up the env-var:
$ set -x G13_IN /run/g13d/g13-0
$ set -x G13_OUT /run/g13d/g13-0_out
⚠️
Please note that the indicated pipe paths are included and compiled.
If the paths ever change, it will be necessary to recompile the whole app.

Also, you have to kown what applications you want and select the features you want. Keep them in mind, we will need that soon.

Build and Install

Now you have two ways in front of you: cargo install or clone, build and copy.

Cargo install

With cargo install, all you have to do is :

$ cargo install --git https://github.com/fusetim/g13-apps [--features <feature1> [feature2..] ]

This command will build G13 Apps with the given features and install it at $HOME/.cargo/bin/g13-apps (by default, look for --root for custom path).

Clone, Build and Copy

To build g13-apps, you need to clone the repo:

$ git clone https://github.com/fusetim/g13-apps.git

And finally, you can build the apps with all the features you want:

$ cargo build --release [--features <feature1> [feature2..] ]

And now, enjoy your new application at ./target/release/g13-apps.

If you want to use g13-apps as a system app or a user service, you should now copy the binary in a PATH-known directory or add it to your path. For the user service, any directory can work.

Install as a user service

ℹ️
These steps focus on the systemd User Service. Feel free to do a PR to add another system.

Now you surely want to use tis app as a user system and not launch it by yourself. So, check out the g13-apps.service and install it in $HOME/.config/systemd/user/.

You should now enable it with:

$ systemctl --user enable g13-apps

and you can start it:

$ systemctl --user start g13-apps

Now, g13-apps will be launch when you boot :)

Keybinds

All you have to do now is configure the right key-binding (in the G13 driver’s config) and you will be able to take advantage of all the applications you have chosen. See g13-apps.bind for example.

By default, the G13 keybinds is at /etc/g13d/default.bind.

And finally, you can now use all the powers of this g13 apps.

License

© 2020 - FuseTim
All rights reserved

Program offered under license CeCILL v2.1[1]
License in French | License in English


1. Free license under French law compatible with the GNU GPL licenses. See section 5.3.2.